t7584
Mar 8th 2006, 9:44 am
I want to create a search utility and it's necessary to write SQL statement.
Is this correct? - sSQL="SELECT * FROM r1 ORDER BY ID DESC WHERE r1.message LIKE '%" & strInputSearch & "%';"
Or like this? - sSQL="SELECT * FROM r1 WHERE r1.message LIKE '%" & strInputSearch & "%' ORDER BY ID DESC;"
Is this correct? - sSQL="SELECT * FROM r1 ORDER BY ID DESC WHERE r1.message LIKE '%" & strInputSearch & "%';"
Or like this? - sSQL="SELECT * FROM r1 WHERE r1.message LIKE '%" & strInputSearch & "%' ORDER BY ID DESC;"