I'm trying to create a query my MySQL database using RMySQL. I want to find all queries that contain a variable I provide through R.
For example:
z="name"
dbSendQuery(conn, "SELECT Address FROM Test WHERE Business Like '%z%'")
Wher conn is my connection to my database, Address and Business are columns in a table Test.
This doesn't work, as this causes the query to search for rows that contain the letter z, rather than what the variable z stands for. Any suggestions?