Mysql Error 1604
Contents |
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more error 1064 (42000) about Stack Overflow the company Business Learn more about hiring developers or posting ads
Error Code 1064 Mysql
with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow
Error 1064 Mysql
is a community of 6.2 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up Error 1604 - Wrong Syntax MySQL [closed] up vote -3 down vote favorite Whenever I try to create and insert data into the created table (userid), the error code 1064 comes out (wrong syntax). CREATE TABLE userid ( LogIN int NOT NULL, username varchar(40) NOT NULL, pass varchar(40) NOT NULL, PRIMARY KEY LogIN, ); INSERT INTO userid (username, pass) VALUE (kimminseo, lukekms); Can anyone help me? Thanks. mysql sql share|improve this question edited Jul 9 '14 at 15:59 John Conde 156k69289364 asked Jul 9 '14 at 15:58 Kim Minseo 1097 closed as off-topic by John Conde, juergen d, Abhik Chakraborty, Barranka, David Jul 9 '14 at 16:04 This question appears to be off-topic. The users who voted to close gave this specific reason:"This question was caused by a problem that can no longer be reproduced or a simple typographical error. While similar questions may be on-topic here, this one was resolved in a manner unlikely to help future readers. This can often be avoided by identifying and closely inspecting the shortest program necessary to reproduce the problem before posting." – John Conde, juergen d, Abhik Chakraborty, Barranka, DavidIf this question can be reworded to fit the rules in the help center, please edit the question. 1 The error message would point you in the right direction. –John Conde Jul 9 '14 at 15:59 1 logIn should be autoincrement –zzapper Jul 9 '14 at 16:00 add a comment| 1 Answer 1 active oldest votes up vote 0 down vote accepted You're missing quotes around your string values: INSERT INTO userid (username, pass) VALUE ('kimminseo', 'lukekms'); share|improve this answer answered Jul 9 '14 at 15:59 community wiki John Conde Thx, but I think there is another proble
DOMAINS WEB DESIGN WEB DESIGN SERVICES CREATE YOUR OWN WEBSITE SITE HOSTING TOOLS MEET US MEET US ABOUT US PARTNERS & AWARDS BLOG WE'RE HIRING CONTACT US AMP LOGIN SUPPORT CENTER Search Support Center Product Guides Dedicated Hosting Reseller Hosting KnowledgeBase Website Email Domain Names Reseller Billing Community Support Browse Questions Ask a Question User Submitted Articles Education Channels Android BoldGrid cPanel DokuWiki Drupal 7 Drupal 8 Everything Email Joomla 2.5 Joomla 3.1 K2 Magento 1.6 Mambo MediaWiki http://stackoverflow.com/questions/24658491/error-1604-wrong-syntax-mysql Moodle Movable Type OpenCart OpenCart 2.0 osCommerce PHP-Fusion PHP-Nuke phpBB phpList Premium Website Builder PrestaShop 1.5 PrestaShop 1.6 SMF Tiki Wiki VirtueMart 3 Web Hosting Manager Website Design WordPress Tools & Resources Email Configuration Blacklist Check Visual DNS Lookup Quick Tagger Icon Sets Favicon Generator Bounce Back Parser What is my IP address? >>Website http://www.inmotionhosting.com/support/website/database-troubleshooting/error-1064 .htaccess (17)Adobe Flash (2)APIs (2)Backup and Restore (15)Billing (8)Browser Issues (2)Connecting to a Database (5)cPanel (26)cPanel Account Management (16)Cron Jobs (4)Cube Cart (2)Database Setup (5)Database Troubleshooting (6)Domain Management (2)Dreamweaver (12)Drush (2)eCommerce (7)Elasticsearch (4)Fantastico (4)File Management (16)File Manager (6)FTP (10)FTP Client Setup (21)General Server Setup / Management (15)Getting Started Guides (18)Ghost (3)Google Tools (21)How To (23)HTML (2)Image Editing (2)IP Addresses (3)iWeb (1)JavaScript (2)Joomla (10)Joomla 2.5 (36)Koken (11)Linux (27)Logaholic (5)Magento (2)Maintaining Your Website (1)Managing Files (7)Microsoft FrontPage (11)Microsoft Publisher (1)ModSecurity (7) MODx (3)New Customers (7)Open Classifieds (1)PCI Compliance (7)PHP (15)PHP Configuration (7)PHP Troubleshooting (6)phpBB (25)phpMyAdmin (10)Premium Website Builder (22)Prestashop (1)Protecting Files (5)Publishing Your Site (2)Python (1)Redirects (4)Restricting Bots (5)Search Engine Optimization (1)Secure Socket Layer (SSL) Tutorials (13)Security (12)Sending Email From Websites (2)Server Security (2)Server Usage (21)Slow Websites (7)Social Media (4)Software FAQs (11)Soho Web Builder (18)SSH and Root access (21)Statistics/Logging (12)Troubleshooting Comment Spam (3)Troubleshooting Hacked Websites (9)Web Host Manager (7)Website Error Numbers (4)Website Is Unavailable (3)Website Transfers (6)Website Troubleshooting (26)Welcome to AMP (22)What
Connectors More MySQL.com Downloads Developer Zone Section Menu: Documentation Home MySQL 5.5 Reference Manual Preface and Legal Notices General Information Installing and Upgrading MySQL Tutorial MySQL Programs MySQL Server Administration Security Backup and https://dev.mysql.com/doc/refman/5.5/en/error-messages-server.html Recovery Optimization Language Structure Globalization Data Types Functions and Operators SQL Statement Syntax http://www.codingforums.com/mysql/253879-error-1604-what-am-i-doing-wrong.html The InnoDB Storage Engine Alternative Storage Engines High Availability and Scalability Replication MySQL Cluster NDB 7.2 Partitioning Stored Programs and Views INFORMATION_SCHEMA Tables MySQL Performance Schema Connectors and APIs Extending MySQL MySQL Enterprise Edition MySQL Workbench MySQL 5.5 Frequently Asked Questions Errors, Error Codes, and Common Problems Sources of Error Information error 1064 Types of Error Values Server Error Codes and Messages Client Error Codes and Messages Problems and Common Errors How to Determine What Is Causing a Problem Common Errors When Using MySQL Programs Access denied Can't connect to [local] MySQL server Lost connection to MySQL server Client does not support authentication protocol Password Fails When Entered Interactively Host 'host_name' is blocked Too many connections Out of mysql error 1604 memory MySQL server has gone away Packet Too Large Communication Errors and Aborted Connections The table is full Can't create/write to file Commands out of sync Ignoring user Table 'tbl_name' doesn't exist Can't initialize character set File Not Found and Similar Errors Table-Corruption Issues Administration-Related Issues Problems with File Permissions How to Reset the Root Password What to Do If MySQL Keeps Crashing How MySQL Handles a Full Disk Where MySQL Stores Temporary Files How to Protect or Change the MySQL Unix Socket File Time Zone Problems Query-Related Issues Case Sensitivity in String Searches Problems Using DATE Columns Problems with NULL Values Problems with Column Aliases Rollback Failure for Nontransactional Tables Deleting Rows from Related Tables Solving Problems with No Matching Rows Problems with Floating-Point Values Optimizer-Related Issues Table Definition-Related Issues Problems with ALTER TABLE TEMPORARY Table Problems Known Issues in MySQL Restrictions and Limits Indexes MySQL Glossary Related Documentation MySQL 5.5 Release Notes Download this Manual PDF (US Ltr) - 26.7Mb PDF (A4) - 26.7Mb PDF (RPM) - 25.8Mb EPUB - 6.7Mb HTML Download (TGZ) - 6.4Mb HTML Download (Zip) - 6.5Mb HTML Download (RPM) - 5.5Mb Eclipse Doc Plug
New? Today's Posts FAQ Rules Guidelines Search Advanced Search Forum :: Server side development MySQL Error #1604 - What am I doing wrong? If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. Enjoy an ad free experience by logging in. Not a member yet? Register. Results 1 to 5 of 5 Thread: Error #1604 - What am I doing wrong? Thread Tools Show Printable Version Email this Page… Subscribe to this Thread… Rate This Thread Current Rating Excellent Good Average Bad Terrible 03-12-2012,05:59 AM #1 Developr View Profile View Forum Posts New Coder Join Date Mar 2009 Posts 68 Thanks 0 Thanked 0 Times in 0 Posts Error #1604 - What am I doing wrong? Completely dumbfounded here... Code: CREATE TABLE alerts ( id int(10) NOT NULL auto_increment primary key, to varchar(30) NOT NULL, from varchar(30) NOT NULL, message varchar(1000) NOT NULL, read int(1) NOT NULL ); and the error I get is #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 'to varchar(30) NOT NULL, from varchar(30) NOT NULL, message varchar(10' at line 3 Thanks. Reply With Quote 03-12-2012,07:51 AM #2 abduraooft View Profile View Forum Posts Supreme Master coder! Join Date Mar 2007 Location N/A Posts 15,028 Thanks 164 Thanked 2,247 Times in 2,234 Posts TO is a reserved word for mysql. You'd need to enclose them using backticks (``) to use in your queries as a table/field name. Using a different name is the best practice. The Dream is not what you see in sleep; Dream is the thing which doesn't let you sleep. --(Dr. APJ. Abdul Kalam) 101 ways to post unanswerable questions in CF! Reply With Quote 03-12-2012,05:10 PM #3 Developr View Profile View Forum Posts New Coder Join Date Mar 2009 Posts 68 Thanks 0 Thanked 0 Times in 0 Posts I've tried changing it and it still gives me an error. Reply With Quote 03-12-2012,08:11 PM #4 Keleth View Profile View Forum Posts Senior Coder Join Date Jun 2008 Location New Jersey Posts 2,547 Thanks 45 Thanked 259 Times in 256 Posts Give us the new code? Actually, don't bother... read http://dev.mysql.com/doc/refman/5.5/...ved-words.html from and read are also reserved words. Reply With Quote 03-13-2012,06:31 AM #5 abduraooft View Profile View Forum Posts Supreme Master coder! Join Date Mar 2007 Location N/A Posts 15,028 Thanks 164 Thanked