skip to Main Content

I am not proficient in MySQL and phpMyAdmin and got this error when trying to import my SQL file to a new installation of WAMP. I was developing a joomla website on my local pc and after completion, decided to launch it online with Rochen web hosting. When importing this into my Cpanel, it gave me the error below.

Error

Static analysis:

  1. errors were found during analysis.

    A closing bracket was expected. (near “)” at position 276)

SQL query:

  • Database: kwadi.

Table structure for table iq2rf_assets:

CREATE TABLE `iq2rf_assets` 
( 
  `id` int(10) UNSIGNED NOT NULL COMMENT 'Primary Key', 
   `parent_id` int(11) NOT NULL DEFAULT '0'COMMENT 
)

MySQL said: Documentation

#1064 – You have an error in your SQL syntax; check the manual that
corresponds to your MariaDB server version for the right syntax to use
near ‘)’ at line 14

I tried to resolve with their support but their advice was for me to upgrade my WAMP Server on my local pc to the one that has MariaDB in it and try extract. Now after installing the new WAMP server i am faced with the same issue when trying to import my back up db using phpmyadmin.

It is giving me the same error. I do not know what to do.

Need assistance.

2

Answers


  1. CREATE TABLE iq2rf_assets ( id int(10) UNSIGNED NOT NULL COMMENT 'Primary Key', parent_id int(11) NOT NULL DEFAULT '0')
    

    You do not have a comment on the second field (parent_id), yet you are using the keyword “COMMENT” only to be closing the query after that. Remove it and you’re good to go

    Login or Signup to reply.
  2. The assets table has more fields than the 2 fields shown in your post.
    This is the reason for the failed import, check your export.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search