[Zope] In desparate need of some help
Hi there, i am new to zope and i'm in need of some help. I'm using zope as part of my final year project for university. I am using zope with a database i've constructed using MySQL. I've been having trouble sending queries to MySQL for data from the tables in the DB, instead of the required data i get an error message window appear and my python server crashes(which is running on my machine, by the way i'm using version 2.2.2 of zope on windows ME). Somethimes the error message is blank, other times it's PYTHON15.DLL or MYSQL.DLL when it crashes. Also when i submit a query to adddata to a tablezope returns what appears to be a error message in my browser, which the zope control panel is using, but the data is still added to my DB table. When submitting a query to extract data, if my python server doesn't crash, zope returns the following: Error, MySQL.error: have an error in your SQL syntax near ' '', '', '', 2000 )' at line 3 SQL used:SELECT * FROM songdetails WHERE( '', '', '', '', 2000 ) I'd be most grateful if you could provide some answers to any of these probelms as soon as you can. Even if you don't know if you could point me in the direction of someone who does. Cheers Alan
Re: [Zope] In desparate need of some help
On Wednesday 17 January 2001 10:40, alankirk wrote: Hi there, i am new to zope and i'm in need of some help. I'm using zope as part of my final year project for university. I am using zope with a database i've constructed using MySQL. I've been having trouble sending queries to MySQL for data from the tables in the DB, instead of the required data i get an error message window appear and my python server crashes(which is running on my machine, by the way i'm using version 2.2.2 of zope on windows ME). Somethimes the error message is blank, other times it's PYTHON15.DLL or MYSQL.DLL when it crashes. Hmm... not sure about this. All I can suggest is you check to see if MySQL or Python have issues with WindowsME... (wow, people actually run that ??:) Also when i submit a query to add data to a table zope returns what appears to be a error message in my browser, which the zope control panel is using, but the data is still added to my DB table. When submitting a query to extract data, if my python server doesn't crash, zope returns the following: Error, MySQL.error: have an error in your SQL syntax near ' '', '', '', 2000 )' at line 3 My first recommendation would be to grab yourself a good book on SQL. O'Reilly Assoc "MySQL mSQL" is a good reference in your case. The problem with your select statement is it is incorrect. It should be in the form: SELECT field list FROM table WHERE fieldcomparisonvalue [AND|OR] fieldcomparisonvalue ... so, in your particular case, I would guess: SELECT * FROM songdetails WHERE fifthFieldName = 2000 --- - SQL used: SELECT * FROM songdetails WHERE( '', '', '', '', 2000 ) I'd be most grateful if you could provide some answers to any of these probelms as soon as you can. Even if you don't know if you could point me in the direction of someone who does. Cheers Alan Have a better one, Curtis Maloney ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] In desparate need of some help
Not sure why you're crashing but your SQL looks incorrect and incomplete. It should be something more like: select * from songdetails where some_field='' and some_other_field = 2000 ... ; Hope this helps, --jfarr - Original Message - From: "alankirk" [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, January 16, 2001 3:40 PM Subject: [Zope] In desparate need of some help Hi there, i am new to zope and i'm in need of some help. I'm using zope as part of my final year project for university. I am using zope with a database i've constructed using MySQL. I've been having trouble sending queries to MySQL for data from the tables in the DB, instead of the required data i get an error message window appear and my python server crashes(which is running on my machine, by the way i'm using version 2.2.2 of zope on windows ME). Somethimes the error message is blank, other times it's PYTHON15.DLL or MYSQL.DLL when it crashes. Also when i submit a query to add data to a table zope returns what appears to be a error message in my browser, which the zope control panel is using, but the data is still added to my DB table. When submitting a query to extract data, if my python server doesn't crash, zope returns the following: Error, MySQL.error: have an error in your SQL syntax near ' '', '', '', 2000 )' at line 3 SQL used: SELECT * FROM songdetails WHERE( '', '', '', '', 2000 ) I'd be most grateful if you could provide some answers to any of these probelms as soon as you can. Even if you don't know if you could point me in the direction of someone who does. Cheers Alan ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )