cancel
Showing results for 
Search instead for 
Did you mean: 

Create customer groups automatically

Create customer groups automatically

Hi,

 

Is it possible to create customer groups automatically when importing a csv file with customer's information.

I want as many groups as customers.

 

Regards,

lilbag

Tags (1)
6 REPLIES

Re: Create customer groups automatically

Hello.

When you impot customers in order to assign them to customer group you use group ID, not gtroup name. This means that customer group should be created beforehand and then customers are assigned to it using group ID. This is how it works by default.

Store Manager for Magento 1.x and 2.x - inventory management tool to automatically update products, customers, orders, and other data across multiple sales channels and suppliers.

Re: Create customer groups automatically

Hi,

 

first of all, thanj you for your reply.

I don't understand why, when i try to import my csv file the result is :

the value " " is not valid for the field "group"

 

website,email,group_id,firstname,lastname,created_in,is_subscribed

boutique_1,abc@exemple.com,7,Lilian,RIVIERE,default,0

 

there is no group with "7" for ID.

 

Thanks,

lilbag

Re: Create customer groups automatically

Check your file encoding. Re-save it using UTF-8 - this may help

and also the group with ID 7 should be created beforehand, do you have customer group with this ID?

Store Manager for Magento 1.x and 2.x - inventory management tool to automatically update products, customers, orders, and other data across multiple sales channels and suppliers.

Re: Create customer groups automatically

Hi,

 

Well i tried to save it with UTF-8 but it's the same problem.

I don't have group with ID 7.

Just in case i tried 1620 to be sure but it's not changed.

 

Thanks,

lilbag

 

Re: Create customer groups automatically

You cannot simply put any random number to make it ID of customer group. Customer group should be created before import and when it is done there you can get customer group ID. 

Customer group ID cannot be assigned by you, it is auto-incremented by Magento itself when customer group is created.

So you have to go to -

  • Customers -> Customer Groups
  • Press Add new customer group
  • Type Group Name and choose tax class
  • Save customer group
  • After that you can get customer proup id here -

  • Now go to your import file and put there the number that curresponds to one of IDs in the list of your created groups

You can use ONLY  ids that are listed there and cannot make your own IDs, as they are assigned by Magento itself.

Store Manager for Magento 1.x and 2.x - inventory management tool to automatically update products, customers, orders, and other data across multiple sales channels and suppliers.

Re: Create customer groups automatically

Ok, thank you for your reply. I think I misspoke for my first message.

So, we can't create group just by using a random ID during import of a csv file.

I was thinking that was possible to create new groups by the import.


Anyway, thank you.

lilbag