I have a mySQL server that creates daily a new table according to daily date. So i use this code:
Android code:
config file
I get error setting "?" for variable table name
My question is how can i set a mySQL command for a variable table name.
Thank you for your time.
Android code:
B4X:
cmd.Initialize
cmd.Name = "selectAll"
'Parameters for table name
cmd.Parameters = Array As Object("01_01_2017","01_01_2017")
reqManager.ExecuteQuery(cmd,0,"selectAll")
config file
B4X:
sql.selectAll=SELECT * FROM daily.? WHERE daily.?.agms=265475
I get error setting "?" for variable table name
B4X:
<pre> com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''01_01_2017' WHERE daily.'01_01_2017'.agms=265475' at line 1</pre></p>
My question is how can i set a mySQL command for a variable table name.
Thank you for your time.