Unfortunately, you must have the ability to edit the query in the config.properties file (this is also an advantage for security).
In your example, however, you should use:
example config.properties:
######
sql.select_animal=SELECT * FROM table WHERE Name = ? AND Surname = ?"
######
and then pass Name and Surname as parameters.
About bandwidth, I do not understand: if the query is located directly on the server, you will send a smaller number of bytes, not greater.
Sorry for my bad English, but ... I'm italian, like you