In MyBatis, you mark the places where parameters should be inserted into your SQL like so:
SELECT * FROM Person WHERE id = #{id}
You could use bind syntax
Quoting Official documentation
The bind element lets you create a variable out of an OGNL expression and bind it to the context. For example:
SELECT * FROM BLOG WHERE title LIKE #{pattern}