If this is your first visit, check our documentation. To post, register or login.
Forums / Code Matters / Bug Reports / [Fixed v1.5.1] 1062 Duplicate entry '1-1' for key 1 in zen_products_options_values

[Fixed v1.5.1] 1062 Duplicate entry '1-1' for key 1 in zen_products_options_values

Locked

Started by oneeyewilly on 25 Dec 2011, 2:29 AM · Views: 1,456

Results 1 to 4 of 4
This thread is locked. New replies are disabled.
25 Dec 2011, 2:29 AM
#1
oneeyewilly avatar

oneeyewilly

New Zenner

Join Date:
Dec 2011
Posts:
6
Plugin Contributions:
0

Post #1 by oneeyewilly

I am trying to setup dowloads and here is what happens.

I first go to the option name manager and create an option called download, type Radio, order 10. I then go to the option value manager and select download as the option name, set option value to "zip file" and order to 10. When I click on insert I get this message.

1062 Duplicate entry '1-1' for key 1
in:
[insert into zen_products_options_values (products_options_values_id, language_id, products_options_values_name, products_options_values_sort_order) values ('1', '1', 'zip file', '10')]
If you were entering information, press the BACK button in your browser and re-check the information you had entered to be sure you left no blank fields.

I hit the back button and make sure I don't have any blank fields, but same error.

ne1 know what is going on or how to fix it? thank you

Michael

25 Dec 2011, 4:53 AM
#2
oneeyewilly avatar

oneeyewilly

New Zenner

Join Date:
Dec 2011
Posts:
6
Plugin Contributions:
0

Post #2 by oneeyewilly

Holy crap, I figured it out.

Would you like to guess as to what was causing the problem? Naw, here is the answer.

There was a duplicate in the database, under zen_products_options_values that wasn't deleted when I deleted an old value. After I deleted that item in the database, ta-da, I was allowed add option values.

25 Dec 2011, 6:24 AM
#3
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,512
Plugin Contributions:
176

Post #3 by drbyte

oneeyewilly:

I am trying to setup dowloads and here is what happens.

I first go to the option name manager and create an option called download, type Radio, order 10. I then go to the option value manager and select download as the option name, set option value to "zip file" and order to 10. When I click on insert I get this message.

1062 Duplicate entry '1-1' for key 1
in:
[insert into zen_products_options_values (products_options_values_id, language_id, products_options_values_name, products_options_values_sort_order) values ('1', '1', 'zip file', '10')]
If you were entering information, press the BACK button in your browser and re-check the information you had entered to be sure you left no blank fields.

I hit the back button and make sure I don't have any blank fields, but same error.

ne1 know what is going on or how to fix it? thank you

Michael

oneeyewilly:

Holy crap, I figured it out.

Would you like to guess as to what was causing the problem? Naw, here is the answer.

There was a duplicate in the database, under zen_products_options_values that wasn't deleted when I deleted an old value. After I deleted that item in the database, ta-da, I was allowed add option values.
That is indeed the best bandage for the situation.

I've seen this mentioned before, but everyone swore they didn't delete anything. Thanks for fessing up so we can look into it.

.
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.

19 Sep 2012, 3:00 AM
#4
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,512
Plugin Contributions:
176

Post #4 by drbyte

Fixed in v1.5.1

.
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.