no way to import customers in 3.7?

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
7 years ago
pepper wrote:
A. Create table (MyOldCustomersTable) in nop database or different blank database?

Doesn't matter as long as you reference it correctly relative to where you're running the query from but since it's only there temporarily it's probably simpler just to add it in the nop database and delete it after.

pepper wrote:
B. this sql query that i will run on nop db will work without changes?

Mostly, but it's best viewed as a starting point to customise to your needs. For instance it references the Customer table as MERGE AshNop.dbo.Customer (AshNop is the name of the database I was running it over but would need changing or removing).

It's probably best to wrap the whole thing in a transaction that's set to rollback like this:

BEGIN TRANSACTION;
    rest of code here
ROLLBACK

Then you can test it without actually making any changes to the database and change the ROLLBACK to COMMIT once you're happy it's going to do what you want. To be honest if you're not comfortable with SQL then it's not a great idea to be working directly on a live database. I'd do this sort of thing in a development environment until I was 100% sure I'd got it right (and then backup the live database just in case).

pepper wrote:
i have to start query with WITH?

Yes, it defines a series  of common table expressions at the start for generating the salts and hashing the passwords so it starts with WITH BinarySaltyUsers AS...
4 years ago
I just posted my solution for nopCommerce 3.90 here if it helps anybody.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.