| Index
» Projects
» phpMyEdit
» Forum
» Can't Get Values Working from Table/Column |
 |
jaystarkey
Joined: 10 Jun 2005
Posts: 4
Posted: 2005-06-11 07:50
Back to top
Reply with quote
|
I included this in my script for one field:
//$opts['fdd']['ApptDate']['values']['table'] = 'Dates';
//$opts['fdd']['ApptDate']['values']['column'] = 'ClinicDates';
And get this error: 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 '-sta_sfhbc.Dates ORDER BY ClinicDates' at line 1
How can I get this working?
|
ajh
Joined: 17 Dec 2003
Posts: 236
Posted: 2005-06-11 19:10
Back to top
Reply with quote
|
Is Dates a reserved word in MySQL?
|
jaystarkey
Joined: 10 Jun 2005
Posts: 4
Posted: 2005-06-13 07:10
Back to top
Reply with quote
|
| ajh wrote: |
| Is Dates a reserved word in MySQL? |
I don't think so - I tried renaming the table to "ClinicDates" and got:
"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 '-sta_sfhbc.ClinicDates ORDER BY ClinicDates' at line 1"
Could it be because there is a hyphen in the database name? The error message doesn't include the full table name, the-sta_sfhbc.ClinicDates?
|
michal
Joined: 17 Jun 2003
Posts: 537
Location: Slovakia
Posted: 2005-06-13 08:53
Back to top
Reply with quote
|
hyphens {-} are bad... try to put them in `, but that can have some sideeffects, or rename the database...
|
|
Post new topic
Reply to topic
|
|
|
|