Jump to content

I thought this was fixed in CC6.2.1 Database key


Recommended Posts

According to the history of this code in the Github, the change to the schema had to be backed out because empty values (or null) would be in multiple rows - and that is not allowed for a UNIQUE column.

I suppose what should have happened is that the expected schema description should have been updated to not show any discrepancy.

Link to comment
Share on other sites

According to CC621 /setup/db/upgrade/6.2.1.sql, there is:
ALTER TABLE `CubeCart_order_summary` ADD KEY (`custom_oid`);

Then, in CC621 (as compared to CC620), in admin /sources/maintenance.index.inc.php, line 808:
'custom_oid' => 'KEY'
(was: 'custom_oid' => 'UNIQUE KEY')

So, please verify that your admin file /sources/maintenance.index.inc.php, line 808 is correct.

Link to comment
Share on other sites

Here is my lines 806 - 808

'email' => 'KEY',
'order_date' => 'KEY',
'custom_oid' => 'KEY'

I was looking at the structure of my order_summary in the database and I think, I don't really remember,  when this first came up I tried to fix this according to the previous post, but I think I put it back to how it was. Should I do something with this?

 

590089735_dbordersummary.PNG.33fc1907185ae0b25c4d167a2a81f545.PNG

 

Here's what thee line looks like:

2120712564_customoiddbline.thumb.PNG.f721b39168e62da6586706490a3f6d69.PNG

 

 

Edited by Claudia M
More info
Link to comment
Share on other sites

"custom_oid" has a regular KEY and that's good.

At some time, a second occurance of adding a KEY index happened, creating "custom_oid_2". Maybe running the setup script a second time?

Anyway, you may delete the "custom_oid_2" index.

Lines 806-808 are correct for CC621. The question then becomes, from where did CubeCart get information that the column "custom_oid" is expected to have a UNIQUE KEY.

Link to comment
Share on other sites

" The question then becomes, from where did CubeCart get information that the column "custom_oid" is expected to have a UNIQUE KEY. "

I think this was something I did awhile back, before the upgrade, trying to fix the orange error message. What should I do?  I'll delete the custom_oid_2 right now.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...