Forums / General Questions / Importing a customer list in ZenCart

Importing a customer list in ZenCart

Locked

Views: 3,201

Results 1 to 7 of 7
This thread is locked. New replies are disabled.
21 May 2007, 4:45 PM
#1
pierrick avatar

pierrick

New Zenner

Join Date:
Mar 2007
Posts:
25
Plugin Contributions:
0

Importing a customer list in ZenCart

Hi all,

I was confronted with this problem when a client who owns a wholesale business wanted to have all of his clients in ZenCart. He would then do a mailout to notify the clients that they can log in and place orders.

Problem:

  1. What tables get updated when a client is added through ZenCart's interface?
  2. What email address and password should I give the clients I have just added?

Resolution:

  1. The tables are:
<header>_address_book - contain the customers' company names, contact names and addresses.<header>_customers - contain the customers' contact name, email and various other ZenCart parameters (group pricing, referral, etc.)<header>_customers_info - contain some (all?) of the customers' online activity logs. Using phpMyAdmin I obtained the structures of the above files. I then reformatted the existing customer list I had to eventually end up with three matching comma-separated data files. I also created a unique ID for each customer. This is probably the most intricate part of the work as you must know something of data structure, and how to work with phpMyAdmin (which is by the way an excellent tool.) Note: the unique ID MUST be unique. Make sure you do not use any already used by ZenCart. Note: <header>_ corresponds to the header you have specified for your ZenCart tables at installation.
  1. Email address and password
    None of the clients I had to upload had an email address (for whatever reason) so I had to create a UNIQUE one for each client. And of course I also had to create a password.
    Keeping it simple I chose the following format for the email address:
    <customer_id>@<blah.com>
    where <customer_id> is the unique record ID and <blah.com> is some arbitrary domain structure. The whole thing looks enough like a genuine email address to ensure ZenCart is happy with it when the client logs in.
    The password is identical for all clients and it is the encrypted value of an arbitrary word such as: 62c4de849c1af31f90fe125527dd84dd:e3 for the word welcome.

Next step:
BACK-UP your existing data! BACK-UP your existing data! BACK-UP your existing data!
And then simply import the three files into ZenCart, again I used phpMyAdmin to do this.
Check the data has imported properly: count the rows, look at the data, etc

Test thoroughly: login as a client, try changing the password, etc.

Here you go.
Happy zenning!

Pierrick

Kind regards Pierrick

21 May 2007, 6:56 PM
#2
theoracle avatar

theoracle

Suspended

Join Date:
Aug 2004
Posts:
3,180
Plugin Contributions:
1

Re: Importing a customer list in ZenCart

This looks pretty much like the objective you were talking about from this topic:

http://www.zen-cart.com/forum/showpost.php?p=377867&postcount=9

However, I'd like to inform you that I have just finished to design my concept plan for something much more similar. Your request will also be included in this modulation. :wink2:

22 May 2007, 7:51 AM
#3
pierrick avatar

pierrick

New Zenner

Join Date:
Mar 2007
Posts:
25
Plugin Contributions:
0

Re: Importing a customer list in ZenCart

TheOracle:

This looks pretty much like the objective you were talking about from this topic:

http://www.zen-cart.com/forum/showpost.php?p=377867&postcount=9

However, I'd like to inform you that I have just finished to design my concept plan for something much more similar. Your request will also be included in this modulation. :wink2:

Hi,

Yes, you're absolutely right. I was presented with the challenge by my client. Since I couldn't find a contrib that could do it, I got my brains into gear and this is what I came up with.
I was reluctant to put this thread in the 'Contributions' as it isn't one per say. I mean it's not like it presents as a nice formatted page, integrating itself into the admin module, or whatever.
I thought that if someone out there was faced with a similar challenge, at least there'd be some sort of a quick guide.

There's a lot of very helpful people in this forum. I obtained valuable information, which has saved me hours of work and got me a great insight into ZenCart and its inner workings. If this thread helps someone, all the better!

Great to know you'll be designing something along that line, and I am glad you'll be taking my request into consideration.:thumbsup:

Cheers.
Pierrick

Kind regards Pierrick

22 May 2007, 11:55 PM
#4
theoracle avatar

theoracle

Suspended

Join Date:
Aug 2004
Posts:
3,180
Plugin Contributions:
1

Re: Importing a customer list in ZenCart

For now, your instructions could be applied, by wizard basis, when using mySQL-Front software. You can systematically compare each physical SQL fields between two different tables and import your readings into each appropriate fields you might select between the source table and the destination table.

In addition, if I remember correctly, I believe this can also be done from two different databases without the need to export and re-import your table (which I believe the EasyPopulate MOD does unfortunitely but I could be wrong). :wink2:

23 May 2007, 8:17 PM
#5
pierrick avatar

pierrick

New Zenner

Join Date:
Mar 2007
Posts:
25
Plugin Contributions:
0

Re: Importing a customer list in ZenCart

TheOracle:

For now, your instructions could be applied, by wizard basis, when using mySQL-Front software.
Any wizard-based system would be welcome I guess since my method demands a fair bit of basic database knowledge (structures, relationships, etc) as well as a good working knowledge of phpMyAdmin.
TheOracle:

You can systematically compare each physical SQL fields between two different tables and import your readings into each appropriate fields you might select between the source table and the destination table.
One must be careful when doing this in ensuring the integrity of the relationships between the three tables. The method you mention would assume that at the very least all unique ID’s have already been created and checked for integrity.

TheOracle:

In addition, if I remember correctly, I believe this can also be done from two different databases without the need to export and re-import your table (which I believe the EasyPopulate MOD does unfortunitely but I could be wrong).
Not sure what you mean here.:dontgetit
Also I believe EasyPopulate is a chargeable add-on. I'm thinking of a free contrib here.:wink2:

Cheers
Pierrick

Kind regards Pierrick

23 May 2007, 10:37 PM
#6
brent avatar

brent

Totally Zenned

Join Date:
Mar 2005
Location:
United Kingdom
Posts:
606
Plugin Contributions:
0

Re: Importing a customer list in ZenCart

pierrick:

Also I believe EasyPopulate is a chargeable add-on. I'm thinking of a free contrib here.:wink2:

There are two versions. EP and EP Advanced. The standard version is free.

24 May 2007, 7:42 AM
#7
pierrick avatar

pierrick

New Zenner

Join Date:
Mar 2007
Posts:
25
Plugin Contributions:
0

Re: Importing a customer list in ZenCart

Brent:

There are two versions. EP and EP Advanced. The standard version is free.
True, but according to Lange's own description of EP Standard, it "updates/adds products from a tab delimited file", there no mention of customers.
For that matter, it looks like the Advanced version doesn't deal with the customers' side of things either.
EP doesn't seem to be the way to go if one wants to import a customer list. However EP could present an elegant methodology for importing external data into ZenCart.

Cheers
Pierrick

Kind regards Pierrick