Results 1 to 2 of 2

Thread: Give error SQL syntax. Where is the problem ?

  1. #1
    Join Date
    Nov 2006
    Posts
    65
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question Give error SQL syntax. Where is the problem ?

    I have a problem Importing Mysql issues.I import one value well and import the 2nd value by itself but when import more than one value it gives error.

    I import this code(first value) well;
    Code:
    INSERT INTO `jos_ezrealty_country` (`id`, `name`, `published`, `checked_out`, `checked_out_time`, `editor`, `ordering`) VALUES
    ('5', 'AKSARAY', '1', '0', '0000-00-00 00:00:00', 'NULL', '77')
    or second value well;
    Code:
    INSERT INTO `jos_ezrealty_country` (`id`, `name`, `published`, `checked_out`, `checked_out_time`, `editor`, `ordering`) VALUES
    ('6', 'AMASYA', '1', '0', '0000-00-00 00:00:00', 'NULL', '76')
    But when import two value it gives error;

    Code:
    INSERT INTO `jos_ezrealty_country` (`id`, `name`, `published`, `checked_out`, `checked_out_time`, `editor`, `ordering`) VALUES
    ('5', 'AKSARAY', '1', '0', '0000-00-00 00:00:00', 'NULL', '77')
    ('6', 'AMASYA', '1', '0', '0000-00-00 00:00:00', 'NULL', '76')
    Error this;
    #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 '('6', 'AMASYA', '1', '0', '0000-00-00 00:00:00', 'NULL', '76')' at line 3

    What is the solution please

  2. #2
    Join Date
    Nov 2006
    Posts
    65
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Ok I found I miss comma;
    Code:
    INSERT INTO `jos_ezrealty_country` (`id`, `name`, `published`, `checked_out`, `checked_out_time`, `editor`, `ordering`) VALUES
    ('5', 'AKSARAY', '1', '0', '0000-00-00 00:00:00', 'NULL', '77'),
    ('6', 'AMASYA', '1', '0', '0000-00-00 00:00:00', 'NULL', '76')

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •