Zen Cart Logo
Forums / General Questions / Using category and product DB tables from another installation?

Using category and product DB tables from another installation?

Locked

Views: 1,299

Results 1 to 7 of 7
This thread is locked. New replies are disabled.
16 May 2006, 8:37 AM
#1
walshy avatar

walshy

New Zenner

Join Date:
May 2006
Posts:
3
Plugin Contributions:
0

Using category and product DB tables from another installation?

Hi,

I was wondering if anyone has atempted to run two sperate installations of ZenCart referencing the categories and products from another installation in the same db?

We have two sites a retail site and a trade site, we would like the trade site to have its own admin options (hence why we can't just use the same database entirely) and reference the retail site for category and product details.

Any ideas would be much appreciated? Thanks

16 May 2006, 9:10 AM
#2
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: Using category and product DB tables from another installation?

As there are very many interlinks between tables this sounds as though it would be a disaster. What I am specifically referencing is there is a reason that you don't use the same full DB, like prices, discounts etc and these are all contained within the products table. If you have phpMyadmin look at the contents of one of the tables you are referring to. The ZenID is also there and used as an item is added be it category or product. One glitch in this numbering would kill the whole shop.

I would suggest that you find the EZpopulate Mod and using this to add/maintain your DB you could enter once and apply to both DB's. But you would maintain fully separate DB for each shop.

16 May 2006, 9:15 AM
#3
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: Using category and product DB tables from another installation?

Also, I do not know how you operate you business, but if it is simply that your trade site receives a standard discount over all purchases you can setup a discount group i.e. trade members, and specify the % discount they receive. If this would suffice then there would be no requirement for 2 shops and it could all be run from one install.

Just a feature that you might not have been aware of.

16 May 2006, 9:16 AM
#4
misty avatar

misty

Inactive

Join Date:
Apr 2004
Location:
UK
Posts:
5,752
Plugin Contributions:
1

Re: Using category and product DB tables from another installation?

I would suggest that you find the EZpopulate Mod and using this to add/maintain your DB you could enter once and apply to both DB's. But you would maintain fully separate DB for each shop.
Walshy, Listen to kobra, your initial idea is fraught with danger!!
:wink2:

16 May 2006, 10:30 AM
#5
walshy avatar

walshy

New Zenner

Join Date:
May 2006
Posts:
3
Plugin Contributions:
0

Re: Using category and product DB tables from another installation?

Thanks for your help guys.

It does sound like it would be a nightmare to have the two integrated! We are just trying to save time by not needing to submit a product twice in both admins. I'll look in to this EZPopulate mod it may be much easier than trying to play around with the code!\

Thanks again

16 May 2006, 11:14 AM
#6
misty avatar

misty

Inactive

Join Date:
Apr 2004
Location:
UK
Posts:
5,752
Plugin Contributions:
1

Re: Using category and product DB tables from another installation?

trying to save time
Good decision Walshy, in this instance" more haste, less speed" would apply
if/when messing around with zencart admin config
:smile:

16 May 2006, 11:27 AM
#7
walshy avatar

walshy

New Zenner

Join Date:
May 2006
Posts:
3
Plugin Contributions:
0

Re: Using category and product DB tables from another installation?

A programmer we use has suggested that he write a synchronizing script that will check for updates and add/delete/edit products from the second database. This can be done on a button press in the admin, triggered on admin logout or ran as a cron job from the server.

I will make the code available if anyone needs it, thats if it works out that is!