

- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Fix MySQL ERROR 1064 (42000) check the manual that corresponds to your MySQL server version for the right syntax to use near ')'
This error may occur if you have used an incorrect syntax. Let’s say the following is the create table statement −
mysql> create table DemoTable1492 -> ( -> timestamp TIMESTAMP, -> event int, -> ); 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 5
You need to remove extra comma above after the event column to fix. Let us first create a −
mysql> create table DemoTable1492 -> ( -> timestamp TIMESTAMP, -> event int -> ); Query OK, 0 rows affected (0.44 sec)
Insert some records in the table using insert −
mysql> insert into DemoTable1492 values(now(),101); Query OK, 1 row affected (0.09 sec) mysql> insert into DemoTable1492 values(now()+interval 3 month,102); Query OK, 1 row affected (0.14 sec)
Display all records from the table using select command −
mysql> select * from DemoTable1492;
This will produce the following output −
+---------------------+-------+ | timestamp | event | +---------------------+-------+ | 2019-10-06 10:56:53 | 101 | | 2020-01-06 10:57:07 | 102 | +---------------------+-------+ 2 rows in set (0.00 sec)
- Related Questions & Answers
- Resolve usage of quotes 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?
- How to fix error “You have an error in your syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near… ”?
- How to resolve the MySQL 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?”
- MySQL server version for the right syntax to use near 'OPTION SQL_SELECT_LIMIT=10'?
- Fix MySQL Error #1064 - You have an error in your SQL syntax… near 'TYPE=MyISAM?
- Resolve MySQL ERROR 1064 (42000): You have an error in your syntax?
- Fix ERROR 1064 (42000) while creating a database in MySQL?
- Fix MySQL Database Error #1064?
- ERROR 1064 (42000): You have an error in your SQL syntax at zero fill column?
- How to resolve the ERROR 1115 (42000): Unknown character set: 'utf8mb4'?
- Resolve the MySQL error 'TYPE=MyISAM'?
- Resolve ERROR 1064 (42000) that occurred after using varchar (without providing the size)
- How can I check the version of MySQL Server?
- How to easily 'create table from view' syntax in MySQL?
- Solve ERROR 1396 (HY000): Operation DROP USER failed for 'user'@'localhost' in MySql?
Advertisements