Post by digitalinnova » Thu Jun 21, 2018 6:00 pm

Error Code(0): Error: Can't DROP 'PRIMARY'; check that column/key exists
Error No: 1091
ALTER TABLE `oc_category` DROP PRIMARY KEY, ADD PRIMARY KEY(`category_id`, `parent_id`) in /Applications/MAMP/htdocs/tt_presiden/system/library/db/mysqli.php on line 40

Newbie

Posts

Joined
Thu Jun 21, 2018 5:56 pm

Post by straightlight » Fri Jun 22, 2018 1:09 am

I was sure to have answered this topic prior. Anyway, what was stated is to look on Google / Stackoverflow since the issue you are reporting is not about OC.

The most generated errors being found on Opencart forum originates from contributed programming.

Regards,
Straightlight


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by Johnathan » Fri Jun 22, 2018 3:37 am

I deleted your post because it was not helpful. This issue *is* related to OpenCart, since they're obviously seeing it when trying to install or configure something in OpenCart. While searching Google / Stackoverflow may be helpful, since it's about an OpenCart installation it's a valid question to post in the forum.

digitalinnova: The database query that's being run is not part of standard OpenCart installation that I'm aware of, so you must have an extension installed that is trying to change the primary key on the "category" table. However, the way the database query is being run isn't working, because as it says, it can't drop the primary key. You'll need to contact the author of whatever extension you are using, and ask them to fix the query. If you don't know which extension it is, I would start looking at anything category-related, search-related, or SEO-related.

If you're trying to run this query yourself, then you were informed wrong about the correct MySQL syntax for changing primary keys. I'm not entirely sure what you'd want to do that, so you may want to consult whatever directions you originally read about this, and ask whoever posted it about it.

Image
Image Image Image Image Image Image


User avatar
Global Moderator

Posts

Joined
Fri Dec 18, 2009 3:08 am


Post by straightlight » Fri Jun 22, 2018 10:01 pm

Johnathan wrote:
Fri Jun 22, 2018 3:37 am
I deleted your post because it was not helpful. This issue *is* related to Opencart, since they're obviously seeing it when trying to install or configure something in OpenCart. While searching Google / Stackoverflow may be helpful, since it's about an OpenCart installation it's a valid question to post in the forum.
Contradiction. In addition, my previous reply is already based on clean installations of OC. In this case, it is about a query line.

The most generated errors being found on Opencart forum originates from contributed programming.

Regards,
Straightlight


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON
Who is online

Users browsing this forum: No registered users and 15 guests