Results 1 to 10 of 10
  1. #1
    Join Date
    Mar 2005
    Location
    California
    Posts
    663
    Plugin Contributions
    0

    Default 1062 Duplicate entry '30' for key 1 in [INSERT INTO zen_configuration_group VALUES (3

    Hi, I'm trying to upgrade a ZC store from version 1.2.6 to the lastest 1.3.0.2.

    I got the following message when trying to upgrade the database:
    1062 Duplicate entry '30' for key 1
    in:
    [INSERT INTO zen_configuration_group VALUES (30, 'EZ-Pages Settings', 'EZ-Pages Settings', 30, '1');]

    Did everything go OK? Or do I need to do something else?

    OK...I just checked the catalog folder and I get this message:
    1054 Unknown column 'startdate' in 'field list'
    in:
    [select startdate, counter, session_counter from zen_counter_history where startdate='20060626']

  2. #2
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: 1062 Duplicate entry '30' for key 1 in [INSERT INTO zen_configuration_group VALUE

    Sounds like you have an add-on that is using 30
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  3. #3
    Join Date
    Mar 2005
    Location
    California
    Posts
    663
    Plugin Contributions
    0

    Default Re: 1062 Duplicate entry '30' for key 1 in [INSERT INTO zen_configuration_group VALUES (3

    Please excuse my ignorance. I did have EasyPopulate on my previous installation. Do you think that's what's causing that? Should I uninstall it first?

    Thanks.

  4. #4
    Join Date
    Jan 2004
    Posts
    66,364
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: 1062 Duplicate entry '30' for key 1 in [INSERT INTO zen_configuration_group VALUE

    Quote Originally Posted by tj1
    from version 1.2.6 to the lastest 1.3.0.2.

    I got the following message when trying to upgrade the database:
    1062 Duplicate entry '30' for key 1
    in:
    [INSERT INTO zen_configuration_group VALUES (30, 'EZ-Pages Settings', 'EZ-Pages Settings', 30, '1');]

    Did everything go OK? Or do I need to do something else?
    No, everything did not go okay.

    Use your text editor to edit your /zc_install/mysql_upgrade_zencart_130_to_1301.sql
    around line 15 you'll see this:
    Code:
    INSERT INTO configuration_group VALUES ('30', 'EZ-Pages Settings', 'EZ-Pages Settings', 30, '1');
    Put a # in front of it, like this:
    Code:
    #INSERT INTO configuration_group VALUES ('30', 'EZ-Pages Settings', 'EZ-Pages Settings', 30, '1');
    Save the file and upload back to your server.
    Then rerun zc_install/index.php and select Database Upgrade. Be sure to run the step for v1.3.0-to-1.3.0.1, as well as the 1301-to-1302
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  5. #5
    Join Date
    Mar 2005
    Location
    California
    Posts
    663
    Plugin Contributions
    0

    Default Re: 1062 Duplicate entry '30' for key 1 in [INSERT INTO zen_configuration_group VALUES (3

    Thank you for that suggestion DrByte, just wanted to mention that it appears to have updated from 1.2.6 to 1.2.7, but it's from 1.2.7 to 1.3 that I seem to be having this problem.

    So do I edit mysql_upgrade_zencart_127_to_130.sql instead?

  6. #6
    Join Date
    Mar 2005
    Location
    California
    Posts
    663
    Plugin Contributions
    0

    Default Re: 1062 Duplicate entry '30' for key 1 in [INSERT INTO zen_configuration_group VALUES (3

    I went ahead and did just that. it seems to have upgraded just fine to 1.3.0 now, got the following statements, but I'm guessing that's OK:

    SKIPPED: Cannot insert configuration_key "DEFINE_BREADCRUMB_STATUS" because it already exists
    SKIPPED: Cannot insert configuration_key "ACCOUNT_FAX_NUMBER" because it already exists
    SKIPPED: Cannot insert configuration_key "SHOW_CUSTOMER_GREETING" because it already exists
    SKIPPED: Cannot insert configuration_key "SKIP_SINGLE_PRODUCT_CATEGORIES" because it already exists
    SKIPPED: Cannot insert configuration_key "DOWNLOAD_IN_CHUNKS" because it already exists
    SKIPPED: Cannot insert configuration_key "IMAGE_USE_CSS_BUTTONS" because it already exists
    SKIPPED: Cannot insert configuration_key "LANGUAGE_DEFAULT_SELECTOR" because it already exists
    SKIPPED: Cannot insert configuration_key "SHOW_ACCOUNT_LINKS_ON_SITE_MAP" because it already exists
    SKIPPED: Cannot insert configuration_key "EMAIL_SEND_MUST_BE_STORE" because it already exists
    SKIPPED: Cannot insert configuration_key "DEFINE_DISCOUNT_COUPON_STATUS" because it already exists


    ...now on to try 1.3.0.1 and 1.3.0.2, fingers crossed. :)

  7. #7
    Join Date
    Mar 2005
    Location
    California
    Posts
    663
    Plugin Contributions
    0

    Default Re: 1062 Duplicate entry '30' for key 1 in [INSERT INTO zen_configuration_group VALUES (3

    ...well, it seems to have upgraded to 1.3.0.2 now. Although i did get this message on the last upgrade from 1.3.0.1 to 1.3.0.2:
    ****************
    1062 Duplicate entry 'Administrator' for key 2
    in:
    [INSERT INTO zen_query_builder ( query_category , query_name , query_description , query_string ) VALUES ('email,newsletters', 'Administrator', 'Just the email account of the current administrator', 'select \'ADMIN\' as customers_firstname, admin_name as customers_lastname, admin_email as customers_email_address from TABLE_ADMIN where admin_id = $SESSION:admin_id');]
    *****************

    Is this something to be worried about or am I now finished with the upgrade as far as upgrading the database is concerned?

  8. #8
    Join Date
    Jan 2004
    Posts
    66,364
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: 1062 Duplicate entry '30' for key 1 in [INSERT INTO zen_configuration_group VALUE

    You should get around that one by commenting it out as well:
    in the 1301-to-1302.sql file, line 21:
    Code:
    INSERT INTO query_builder ( query_category , query_name , query_description , query_string ) VALUES ('email,newsletters', 'Administrator', 'Just the email account of the current administrator', 'select \'ADMIN\' as customers_firstname, admin_name as customers_lastname, admin_email as customers_email_address from TABLE_ADMIN where admin_id = $SESSION:admin_id');
    becomes
    Code:
    #INSERT INTO query_builder ( query_category , query_name , query_description , query_string ) VALUES ('email,newsletters', 'Administrator', 'Just the email account of the current administrator', 'select \'ADMIN\' as customers_firstname, admin_name as customers_lastname, admin_email as customers_email_address from TABLE_ADMIN where admin_id = $SESSION:admin_id');
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  9. #9
    Join Date
    Mar 2005
    Location
    California
    Posts
    663
    Plugin Contributions
    0

    Default Re: 1062 Duplicate entry '30' for key 1 in [INSERT INTO zen_configuration_group VALUES (3

    Thank you very much DrByte.
    Just one final question, will my shop be limited in some way by commenting out those two lines? I guess probably not since 'duplicate' is mentioned, but I'd like to hear from someone who knows.

  10. #10
    Join Date
    Jan 2004
    Posts
    66,364
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: 1062 Duplicate entry '30' for key 1 in [INSERT INTO zen_configuration_group VALUE

    In THIS case, there should be no problem, because the upgrade had already inserted those statements before failing on other ones. All should be fine... in THIS case ... can't speak for others who would follow along and read this thread thinking this might apply to them equally ..... reader beware.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

 

 

Similar Threads

  1. Replies: 5
    Last Post: 7 Mar 2015, 07:56 PM
  2. Replies: 2
    Last Post: 11 Dec 2012, 03:58 AM
  3. 1062 Duplicate entry '2293' for key 1in:[INSERT INTO orders_status_history
    By windwoman in forum Managing Customers and Orders
    Replies: 1
    Last Post: 6 Mar 2009, 09:53 AM

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
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR