Re: Moto drops Mysql connection
Jack <[email protected]> 03 Mar 2003 22:33:08 -0700
| Newsgroups | gmane.comp.lang.moto.user |
|---|---|
| Message-ID | <[email protected]> |
Okay, Im missing something....
I have pulled a query off a db, and come up with a sring full of
numbers.
For example one of the strings would be: 3032003
Now I want to do a sql query such as:
String tableName = "transactions";
String query = "select pictures,description from " + tableName + "WHERE
date >" + begin_date;
I keep getting a MySQL Error:
/var/www/site/query.moto:37: Uncaught SQLException
message: You have an error in your SQL syntax near '>3032003' at
line 1
Now when I run this query directly in MySQL:
select * from transactions where date >= 28012003;
I get all kinds of information.
Im not sure what Im doing wrong, but it seems I've tried plenty of
permutations of the same thing with no luck.
Anyone help?
THanks,
Jack