ERROR 1064 (42000): You have an error in your SQL syntax;
Hi All, gee I really hate bugging you all for this. I looked at this page, http://dev.mysql.com/doc/refman/5.0/en/alter-table.html which has this, To change column |a| from |INTEGER| to |TINYINT NOT NULL| (leaving the name the same), and to change column |b| from |CHAR(10)| to |CHAR(20)| as well as renaming it from |b| to |c|: ALTER TABLE t2 MODIFY a TINYINT NOT NULL, CHANGE b c CHAR(20); for changing the name of a column, right? So, why doesn't the below work? mysql ALTER TABLE actors CHANGE director_id actor_id; I get this, ERROR 1064 (42000): 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 '' at line 1 Sorry, little confused right about now, eh. Cheers. Mark Sargent. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: ERROR 1064 (42000): You have an error in your SQL syntax;
At 0:09 +1000 8/6/06, Mark Sargent wrote: ALTER TABLE t2 MODIFY a TINYINT NOT NULL, CHANGE b c CHAR(20); for changing the name of a column, right? So, why doesn't the below work? mysql ALTER TABLE actors CHANGE director_id actor_id; I'm no great expert myself, but off the top of my head, maybe you need to specify the type even if it's unchanged (I assume all you want to do is rename the column?). So supposing director_id was a SMALLINT(3) UNSIGNED, try: ALTER TABLE actors CHANGE director_id actor_id SMALLINT(3) UNSIGNED; Any good? -- Cheers... Chris Highway 57 Web Development -- http://highway57.co.uk/ If at first you don't succeed, try, try again. Then quit. No use being a damn fool about it. -- W.C. Fields -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
re: ERROR 1064 (42000): You have an error in your SQL syntax;
Mark, With the CHANGE clause of ALTER TABLE statement, you must provide the column definition, so something like this is what you need: ALTER TABLE actors CHANGE director_id actor_id MEDIUMINT UNSIGNED NOT NULL; or whatever your original definition is. AFAIK there is no way to rename a column without giving the column type. --Rob Hi All, gee I really hate bugging you all for this. I looked at this page, http://dev.mysql.com/doc/refman/5.0/en/alter-table.html which has this, To change column |a| from |INTEGER| to |TINYINT NOT NULL| (leaving the name the same), and to change column |b| from |CHAR(10)| to |CHAR(20)| as well as renaming it from |b| to |c|: ALTER TABLE t2 MODIFY a TINYINT NOT NULL, CHANGE b c CHAR(20); for changing the name of a column, right? So, why doesn't the below work? mysql ALTER TABLE actors CHANGE director_id actor_id; I get this, ERROR 1064 (42000): 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 '' at line 1 Sorry, little confused right about now, eh. Cheers. Mark Sargent. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED] __ This email has been scanned by the MessageLabs Email Security System. For more information please visit http://www.messagelabs.com/email __ -- Original Message -- FROM: Mark Sargent [EMAIL PROTECTED] TO:mysql@lists.mysql.com DATE: Thu, 08 Jun 2006 00:09:45 +1000 SUBJECT: ERROR 1064 (42000): You have an error in your SQL syntax; Hi All, gee I really hate bugging you all for this. I looked at this page, http://dev.mysql.com/doc/refman/5.0/en/alter-table.html which has this, To change column |a| from |INTEGER| to |TINYINT NOT NULL| (leaving the name the same), and to change column |b| from |CHAR(10)| to |CHAR(20)| as well as renaming it from |b| to |c|: ALTER TABLE t2 MODIFY a TINYINT NOT NULL, CHANGE b c CHAR(20); for changing the name of a column, right? So, why doesn't the below work? mysql ALTER TABLE actors CHANGE director_id actor_id; I get this, ERROR 1064 (42000): 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 '' at line 1 Sorry, little confused right about now, eh. Cheers. Mark Sargent. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED] __ This email has been scanned by the MessageLabs Email Security System. For more information please visit http://www.messagelabs.com/email __ __ This email has been scanned by the MessageLabs Email Security System. For more information please visit http://www.messagelabs.com/email __ -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: ERROR 1064 (42000): You have an error in your SQL syntax;
You can't just change the name without changing (or stating) the type. ALTER TABLE actors CHANGE director_id actos_id varchar(96) default NULL; J.R. -Original Message- From: Mark Sargent [mailto:[EMAIL PROTECTED] Sent: Wednesday, June 07, 2006 10:10 AM To: mysql@lists.mysql.com Subject: ERROR 1064 (42000): You have an error in your SQL syntax; Hi All, gee I really hate bugging you all for this. I looked at this page, http://dev.mysql.com/doc/refman/5.0/en/alter-table.html which has this, To change column |a| from |INTEGER| to |TINYINT NOT NULL| (leaving the name the same), and to change column |b| from |CHAR(10)| to |CHAR(20)| as well as renaming it from |b| to |c|: ALTER TABLE t2 MODIFY a TINYINT NOT NULL, CHANGE b c CHAR(20); for changing the name of a column, right? So, why doesn't the below work? mysql ALTER TABLE actors CHANGE director_id actor_id; I get this, ERROR 1064 (42000): 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 '' at line 1 Sorry, little confused right about now, eh. Cheers. Mark Sargent. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
re: ERROR 1064 (42000): You have an error in your SQL syntax;
At 15:19 +0100 7/6/06, Rob Desbois wrote: With the CHANGE clause of ALTER TABLE statement, you must provide the column definition, so something like this is what you need: ALTER TABLE actors CHANGE director_id actor_id MEDIUMINT UNSIGNED NOT NULL; or whatever your original definition is. Wow! I was right. I'm learning... :-) -- Cheers... Chris Highway 57 Web Development -- http://highway57.co.uk/ If at first you don't succeed, try, try again. Then quit. No use being a damn fool about it. -- W.C. Fields -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
ERROR 1064: You have an error in your SQL syntax....
I am a newbie here. I created a simple table defined as: create table test ( testID int unsigned not null auto_increment, testName varchar(128) not null, primary key (testID) ) type = MyISAM; Now, I filled out test table, and looking for the testName with max characters. The following caused the same error of: ERROR 1064: 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 'select max(length(testName)) from test)' at line 1 select testName from test where length(testName) = (select max(length(testName)) from test); Then I copied a simple line from MySQL book: select * from president where birth = (select min(birth) from president); and adapted to my table with: select * from test where testName = (select min(testName) from test); and executed it with exactly the same error result. MySQL version I am using is: 4.0.21-standard Please help me why I get this error. Thank you Chuzo -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: ERROR 1064: You have an error in your SQL syntax....
Chuzo, SELECT MAX(LENGTH(...)) FROM ... ought to work. SQL doesn't allow aggregate funcs like MAX() in the WHERE clause. Use HAVING(). For nested queries like SELECT ... WHERE colvalue=(SELECT...) you need version 4.1 or later. Peter Brawley http://www.artfulsoftware.com - Chuzo Okuda wrote: I am a newbie here. I created a simple table defined as: create table test ( testID int unsigned not null auto_increment, testName varchar(128) not null, primary key (testID) ) type = MyISAM; Now, I filled out test table, and looking for the testName with max characters. The following caused the same error of: ERROR 1064: 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 'select max(length(testName)) from test)' at line 1 select testName from test where length(testName) = (select max(length(testName)) from test); Then I copied a simple line from MySQL book: select * from president where birth = (select min(birth) from president); and adapted to my table with: select * from test where testName = (select min(testName) from test); and executed it with exactly the same error result. MySQL version I am using is: 4.0.21-standard Please help me why I get this error. Thank you Chuzo -- No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.0.308 / Virus Database: 266.9.5 - Release Date: 4/7/2005 -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
error in your SQL syntax
I have a problem. 1064 - You have an error in your SQL syntax near '(((specials INNER JOIN (products_to_categories INNER JOIN categories ON products' at line 2 SELECT DISTINCT specials.specials_id, products_to_categories.products_id, categories.parent_id, products_description.products_name, products.products_price, products.products_tax_class_id, products.products_image, specials.specials_new_products_price, languages.languages_id FROM languages INNER JOIN (((specials INNER JOIN (products_to_categories INNER JOIN categories ON products_to_categories.categories_id = categories.categories_id) ON specials.products_id = products_to_categories.products_id) INNER JOIN products ON specials.products_id = products.products_id) INNER JOIN products_description ON specials.products_id = products_description.products_id) ON languages.languages_id = products_description.language_id WHERE (((categories.parent_id)=285) AND ((languages.languages_id)=1)) i run this query in my computer and work, but in the internet server don´t. If anyone can solve this problem answer me. Daniel Sousa
Re: error in your SQL syntax
You have an awful lot of brackets in the query, many of which don't appear to be needed. For example, I don't see why you have brackets in this phrase: AND ((languages.languages_id)=1)) Perhaps removing the unnecessary ones will help the query work better and more consistently on each machine. Are the different machines all running the exact same version of MySQL? Rhino - Original Message - From: Daniel Sousa [EMAIL PROTECTED] To: mysql@lists.mysql.com Sent: Wednesday, January 26, 2005 6:45 AM Subject: error in your SQL syntax I have a problem. 1064 - You have an error in your SQL syntax near '(((specials INNER JOIN (products_to_categories INNER JOIN categories ON products' at line 2 SELECT DISTINCT specials.specials_id, products_to_categories.products_id, categories.parent_id, products_description.products_name, products.products_price, products.products_tax_class_id, products.products_image, specials.specials_new_products_price, languages.languages_id FROM languages INNER JOIN (((specials INNER JOIN (products_to_categories INNER JOIN categories ON products_to_categories.categories_id = categories.categories_id) ON specials.products_id = products_to_categories.products_id) INNER JOIN products ON specials.products_id = products.products_id) INNER JOIN products_description ON specials.products_id = products_description.products_id) ON languages.languages_id = products_description.language_id WHERE (((categories.parent_id)=285) AND ((languages.languages_id)=1)) i run this query in my computer and work, but in the internet server don´t. If anyone can solve this problem answer me. Daniel Sousa No virus found in this incoming message. Checked by AVG Anti-Virus. Version: 7.0.300 / Virus Database: 265.7.2 - Release Date: 21/01/2005 -- No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.0.300 / Virus Database: 265.7.2 - Release Date: 21/01/2005 -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: error in your SQL syntax
Here is your original query, reformatted merely so that we humans can read it better: SELECT DISTINCT specials.specials_id , products_to_categories.products_id , categories.parent_id , products_description.products_name , products.products_price , products.products_tax_class_id , products.products_image , specials.specials_new_products_price , languages.languages_id FROM languages INNER JOIN ( ( (specials INNER JOIN (products_to_categories INNER JOIN categories ON products_to_categories.categories_id = categories.categories_id )ON specials.products_id = products_to_categories.products_id ) INNER JOIN products ON specials.products_id = products.products_id ) INNER JOIN products_description ON specials.products_id = products_description.products_id ) ON languages.languages_id = products_description.language_id WHERE ( ( (categories.parent_id)=285 ) AND ( (languages.languages_id)=1 ) ) This query design stinks (reeks) of being autogenerated by M$ Access. The excessive use of parentheses when they aren't needed and the nested JOINs just complicate the query unnecessarily. May I suggest a simplification? SELECT DISTINCT specials.specials_id , products_to_categories.products_id , categories.parent_id , products_description.products_name , products.products_price , products.products_tax_class_id , products.products_image , specials.specials_new_products_price , languages.languages_id FROM categories INNER JOIN products_to_categories ON products_to_categories.categories_id = categories.categories_id INNER JOIN products ON products.products_id = products_to_categories.products_id INNER JOIN specials ON specials.products_id = products.products_id INNER JOIN products_description ON products.products_id = products_description.products_id INNER JOIN languages ON products_description.language_id = languages.languages_id WHERE categories.parent_id=285 AND languages.languages_id=1; I have also noticed in my Windows command shell that it does not process extremely long lines in pastes from the clipboard well. If you copied that straight from Access to a MySQL prompt, it would have been just one long line of information and the DOS command processor would have eventually stopped taking input mid-query. I suspect that is what caused your otherwise acceptable (and I use that term loosely ;-) ) query to be invalid. The last third of it never made it into the MySQL CLI. When I break my queries into shorter lines (human friendly) and paste them into the MySQL command line interface (CLI), everything works just fine. Just copy the entire query (line breaks and all) onto the clipboard and paste it at the MySQL prompt (if that's how you are doing it) and see if it works now. Notepad is my best friend when working in the CLI. I compose and format long queries in Notepad then copy-paste into MySQL. I know it's doing it the hard way (yes, I have and do use the GUI tools too) but it's how I prefer to analyze certain issues. Shawn Green Database Administrator Unimin Corporation - Spruce Pine Daniel Sousa [EMAIL PROTECTED] wrote on 01/26/2005 06:45:32 AM: I have a problem. 1064 - You have an error in your SQL syntax near '(((specials INNER JOIN (products_to_categories INNER JOIN categories ON products' at line 2 SELECT DISTINCT specials.specials_id, products_to_categories. products_id, categories.parent_id, products_description. products_name, products.products_price, products. products_tax_class_id, products.products_image, specials. specials_new_products_price, languages.languages_id FROM languages INNER JOIN (((specials INNER JOIN (products_to_categories INNER JOIN categories ON products_to_categories.categories_id = categories. categories_id) ON specials.products_id = products_to_categories. products_id) INNER JOIN products ON specials.products_id = products. products_id) INNER JOIN products_description ON specials.products_id = products_description.products_id) ON languages.languages_id = products_description.language_id WHERE (((categories.parent_id)=285) AND ((languages.languages_id)=1)) i run this query in my computer and work, but in the internet server don´t. If anyone can solve this problem answer me. Daniel Sousa
Re: error in your SQL syntax
Thanks, works fines. I use access because i don´t know a GUI tool that make SQL querys more easy. Thanks all again, Daniel Sousa - Original Message - From: [EMAIL PROTECTED] To: Daniel Sousa Cc: mysql@lists.mysql.com Sent: Wednesday, 26 January, 2005 14:57 Subject: Re: error in your SQL syntax Here is your original query, reformatted merely so that we humans can read it better: SELECT DISTINCT specials.specials_id , products_to_categories.products_id , categories.parent_id , products_description.products_name , products.products_price , products.products_tax_class_id , products.products_image , specials.specials_new_products_price , languages.languages_id FROM languages INNER JOIN ( ( (specials INNER JOIN (products_to_categories INNER JOIN categories ON products_to_categories.categories_id = categories.categories_id )ON specials.products_id = products_to_categories.products_id ) INNER JOIN products ON specials.products_id = products.products_id ) INNER JOIN products_description ON specials.products_id = products_description.products_id ) ON languages.languages_id = products_description.language_id WHERE ( ( (categories.parent_id)=285 ) AND ( (languages.languages_id)=1 ) ) This query design stinks (reeks) of being autogenerated by M$ Access. The excessive use of parentheses when they aren't needed and the nested JOINs just complicate the query unnecessarily. May I suggest a simplification? SELECT DISTINCT specials.specials_id , products_to_categories.products_id , categories.parent_id , products_description.products_name , products.products_price , products.products_tax_class_id , products.products_image , specials.specials_new_products_price , languages.languages_id FROM categories INNER JOIN products_to_categories ON products_to_categories.categories_id = categories.categories_id INNER JOIN products ON products.products_id = products_to_categories.products_id INNER JOIN specials ON specials.products_id = products.products_id INNER JOIN products_description ON products.products_id = products_description.products_id INNER JOIN languages ON products_description.language_id = languages.languages_id WHERE categories.parent_id=285 AND languages.languages_id=1; I have also noticed in my Windows command shell that it does not process extremely long lines in pastes from the clipboard well. If you copied that straight from Access to a MySQL prompt, it would have been just one long line of information and the DOS command processor would have eventually stopped taking input mid-query. I suspect that is what caused your otherwise acceptable (and I use that term loosely ;-) ) query to be invalid. The last third of it never made it into the MySQL CLI. When I break my queries into shorter lines (human friendly) and paste them into the MySQL command line interface (CLI), everything works just fine. Just copy the entire query (line breaks and all) onto the clipboard and paste it at the MySQL prompt (if that's how you are doing it) and see if it works now. Notepad is my best friend when working in the CLI. I compose and format long queries in Notepad then copy-paste into MySQL. I know it's doing it the hard way (yes, I have and do use the GUI tools too) but it's how I prefer to analyze certain issues. Shawn Green Database Administrator Unimin Corporation - Spruce Pine Daniel Sousa [EMAIL PROTECTED] wrote on 01/26/2005 06:45:32 AM: I have a problem. 1064 - You have an error in your SQL syntax near '(((specials INNER JOIN (products_to_categories INNER JOIN categories ON products' at line 2 SELECT DISTINCT specials.specials_id, products_to_categories. products_id, categories.parent_id, products_description. products_name, products.products_price, products. products_tax_class_id, products.products_image, specials. specials_new_products_price, languages.languages_id FROM languages INNER JOIN (((specials INNER JOIN (products_to_categories INNER JOIN categories ON products_to_categories.categories_id = categories. categories_id) ON specials.products_id = products_to_categories. products_id) INNER JOIN products ON specials.products_id = products. products_id) INNER JOIN products_description ON specials.products_id = products_description.products_id) ON languages.languages_id
RE: error in your SQL syntax
Try Query Browser ( http://dev.mysql.com/downloads/query-browser ) for building queries for MySQL. Regards, Artem -Original Message- From: Daniel Sousa [mailto:[EMAIL PROTECTED] Sent: Wednesday, January 26, 2005 11:18 AM To: [EMAIL PROTECTED] Cc: mysql@lists.mysql.com Subject: Re: error in your SQL syntax Thanks, works fines. I use access because i don´t know a GUI tool that make SQL querys more easy. Thanks all again, Daniel Sousa - Original Message - From: [EMAIL PROTECTED] To: Daniel Sousa Cc: mysql@lists.mysql.com Sent: Wednesday, 26 January, 2005 14:57 Subject: Re: error in your SQL syntax Here is your original query, reformatted merely so that we humans can read it better: SELECT DISTINCT specials.specials_id , products_to_categories.products_id , categories.parent_id , products_description.products_name , products.products_price , products.products_tax_class_id , products.products_image , specials.specials_new_products_price , languages.languages_id FROM languages INNER JOIN ( ( (specials INNER JOIN (products_to_categories INNER JOIN categories ON products_to_categories.categories_id = categories.categories_id )ON specials.products_id = products_to_categories.products_id ) INNER JOIN products ON specials.products_id = products.products_id ) INNER JOIN products_description ON specials.products_id = products_description.products_id ) ON languages.languages_id = products_description.language_id WHERE ( ( (categories.parent_id)=285 ) AND ( (languages.languages_id)=1 ) ) This query design stinks (reeks) of being autogenerated by M$ Access. The excessive use of parentheses when they aren't needed and the nested JOINs just complicate the query unnecessarily. May I suggest a simplification? SELECT DISTINCT specials.specials_id , products_to_categories.products_id , categories.parent_id , products_description.products_name , products.products_price , products.products_tax_class_id , products.products_image , specials.specials_new_products_price , languages.languages_id FROM categories INNER JOIN products_to_categories ON products_to_categories.categories_id = categories.categories_id INNER JOIN products ON products.products_id = products_to_categories.products_id INNER JOIN specials ON specials.products_id = products.products_id INNER JOIN products_description ON products.products_id = products_description.products_id INNER JOIN languages ON products_description.language_id = languages.languages_id WHERE categories.parent_id=285 AND languages.languages_id=1; I have also noticed in my Windows command shell that it does not process extremely long lines in pastes from the clipboard well. If you copied that straight from Access to a MySQL prompt, it would have been just one long line of information and the DOS command processor would have eventually stopped taking input mid-query. I suspect that is what caused your otherwise acceptable (and I use that term loosely ;-) ) query to be invalid. The last third of it never made it into the MySQL CLI. When I break my queries into shorter lines (human friendly) and paste them into the MySQL command line interface (CLI), everything works just fine. Just copy the entire query (line breaks and all) onto the clipboard and paste it at the MySQL prompt (if that's how you are doing it) and see if it works now. Notepad is my best friend when working in the CLI. I compose and format long queries in Notepad then copy-paste into MySQL. I know it's doing it the hard way (yes, I have and do use the GUI tools too) but it's how I prefer to analyze certain issues. Shawn Green Database Administrator Unimin Corporation - Spruce Pine Daniel Sousa [EMAIL PROTECTED] wrote on 01/26/2005 06:45:32 AM: I have a problem. 1064 - You have an error in your SQL syntax near '(((specials INNER JOIN (products_to_categories INNER JOIN categories ON products' at line 2 SELECT DISTINCT specials.specials_id, products_to_categories. products_id, categories.parent_id, products_description. products_name, products.products_price, products. products_tax_class_id, products.products_image, specials. specials_new_products_price
error in your SQL syntax near 'order by 'Variable_name' ????
Hi, MySQL said: You have an error in your SQL syntax near 'order by 'Variable_name' ASC' at line 1 Any ideas as to what this means, and how to fix it? Thanks, Dave - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
Re: error in your SQL syntax near 'order by 'Variable_name' ????
From: [EMAIL PROTECTED] MySQL said: You have an error in your SQL syntax near 'order by 'Variable_name' ASC' at line 1 Any ideas as to what this means, and how to fix it? Hi Dave, How 'bout sending us the entire SQL statement, please. --- Rodney Broom Programmer: Desert.Net - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
Re: error in your SQL syntax near 'order by 'Variable_name' ????
I don't know anything about MySQL, Ive just been trying(with no luck)to install a forum(Snitz forum from www.snitz.com) on my website. My website is Linux/MySQL/Chilisoft! Im running out of support my host hasn't gotten back with me, and Snitz support doesn't know. So I got to messing around with the control panel on my website and went to MySQL database. I clicked on: Show MySQL system variables. Then I could click on: Variable_name, or Value both give me this: MySQL said: You have an error in your SQL syntax near 'order by 'Value' ASC' at line 1 So I thought this might be what is keeping me from getting my forum started - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
Re: error in your SQL syntax near 'order by 'Variable_name' ????
Hi. On Mon, Oct 01, 2001 at 08:32:42PM -0400, [EMAIL PROTECTED] wrote: I don't know anything about MySQL, Ive just been trying(with no luck)to install a forum(Snitz forum from www.snitz.com) on my website. My website is Linux/MySQL/Chilisoft! Im running out of support my host hasn't gotten back with me, and Snitz support doesn't know. So I got to messing around with the control panel on my website and went to MySQL database. I clicked on: Show MySQL system variables. Then I could click on: Variable_name, or Value both give me this: MySQL said: You have an error in your SQL syntax near 'order by 'Value' ASC' at line 1 This means that the clicking produced an invalid SQL command. Seemingly it wanted to run show variables order by 'Value' ASC which is no valid command (SHOW VARIABLES doesn't allow an ORDER BY clause). So I thought this might be what is keeping me from getting my forum started I assume that has nothin to do with that. If you are interested: The above error seems to stem from the fact that they use a general display this table page and append the wished ordering to the last run SQL statement. This works fine for normal SELECTS. But although SHOW VARIABLES returns a table, you may not append an ORDER BY clause. Just a little oversight from their side, but it should have nothing to do with other problems you may encounter. Bye, Benjamin. -- [EMAIL PROTECTED] - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php