Post by drrevans » Mon Jan 17, 2022 1:05 pm

I am migrating my old orders and customers to my upgraded store. I do not see any data in oc_store table but I am seeing the primary key, store_id used in other tables. The only store information that I am seeing is what is in the oc_settings table. My old database has that table empty and when I test on the local host, there is not any data in that table. I am seeing the foreign key for store Id is zero and that shouldn't be. How is data stored in the oc_store table?
Last edited by drrevans on Mon Jan 17, 2022 9:54 pm, edited 1 time in total.

New member

Posts

Joined
Mon Nov 29, 2021 1:31 am

Post by by mona » Mon Jan 17, 2022 1:25 pm

Please always include your OC version in all four digits on each and every post.
We can presume you are using OC3 but that is about all we can double check on your behalf.

There is store table in the database so something else has gone wrong.
Download the official installation from
https://www.opencart.com/index.php?route=cms/download
which is the same as the version you have installed and double check the sql

This also might help
https://code.tutsplus.com/tutorials/cre ... -cms-22261

DISCLAIMER:
You should not modify core files .. if you would like to donate a cup of coffee I will write it in a modification for you.


Spinning Social : Links : Menus : Payments : Socials : Ads : Screen Backgrounds : Galleries : Headers : Banners : Promos


Expert Member

Posts

Joined
Mon Jun 10, 2019 9:31 am

Post by drrevans » Mon Jan 17, 2022 9:52 pm

by mona wrote:
Mon Jan 17, 2022 1:25 pm
Please always include your OC version in all four digits on each and every post.
We can presume you are using OC3 but that is about all we can double check on your behalf.

There is store table in the database so something else has gone wrong.
Download the official installation from
https://www.opencart.com/index.php?route=cms/download
which is the same as the version you have installed and double check the sql

This also might help
https://code.tutsplus.com/tutorials/cre ... -cms-22261
I installed 3.0.3.8 opencart. It created an oc_store table but it is not being used. The store information that is saved in the admin is inserted in the oc_settings table. But when I look at my data from opencart 1.4.9, that store table is empty. I will read your post because I don't like seeing zero as a primary key which both versions are doing this.

New member

Posts

Joined
Mon Nov 29, 2021 1:31 am

Post by by mona » Mon Jan 17, 2022 10:32 pm

I did not understand your initial post correctly and I am still not sure of the question, if there is any, but it is still the built in multistore capability which will be the answer.

DISCLAIMER:
You should not modify core files .. if you would like to donate a cup of coffee I will write it in a modification for you.


Spinning Social : Links : Menus : Payments : Socials : Ads : Screen Backgrounds : Galleries : Headers : Banners : Promos


Expert Member

Posts

Joined
Mon Jun 10, 2019 9:31 am

Post by drrevans » Tue Jan 18, 2022 2:55 am

by mona wrote:
Mon Jan 17, 2022 10:32 pm
I did not understand your initial post correctly and I am still not sure of the question, if there is any, but it is still the built in multistore capability which will be the answer.
When you install the opencart, it has default tables. One of those tables is oc_store which has the column store_id as the primary key that I see in several tables as the foreign key. That table is empty and the foreign key is 0 which being a SQL Server Developer, I know that there should not be a primary key that is zero. The store is setup in Settings in the admin but those values are saved in the Settings table so what is the oc_store table used for. If I am using the Default store, then there should be at least one row in the oc_store table with a store id of 1. Any additional stores should have a row in that table but that is not the case. So my question is what is the oc_store table for since nothing is being written to it?

New member

Posts

Joined
Mon Nov 29, 2021 1:31 am

Post by xxvirusxx » Tue Jan 18, 2022 5:42 am

drrevans wrote:
Tue Jan 18, 2022 2:55 am
So my question is what is the oc_store table for since nothing is being written to it?
Multistore

My Converted Modules | Opencart Upgrade Service | Free Dashboard Maps | Buy me a beer | My Custom OC 3.0.3.8


User avatar
Expert Member

Posts

Joined
Tue Jul 17, 2012 10:35 pm
Location - România

Post by drrevans » Thu Jan 20, 2022 11:31 pm

So if I add another store, then they start putting data in the oc_store? Thanks for the information but seems like all the store including the default one should go in there but oh well.

New member

Posts

Joined
Mon Nov 29, 2021 1:31 am
Who is online

Users browsing this forum: No registered users and 4 guests