- Posts: 640
- Thank you received: 16
Import users from an external database
- PeterChain
-
Topic Author
- Offline
Less
More
10 years 2 months ago #246414
by PeterChain
Import users from an external database was created by PeterChain
-- HikaShop version -- : 2.6.3
-- Joomla version -- : 3.6.0
-- PHP version -- : 5.6.10
-- Browser(s) name and version -- : Google Chrome 51.0.2704.103 (64-bit)
I have to import customers from an external database into the #__hikashop_user (with custom fields) and the joomla #__users table from my own made component.
Is there an available method for this
or
Can I simply use a query agains #__hikashop_user table.
-- Víctor
-- Joomla version -- : 3.6.0
-- PHP version -- : 5.6.10
-- Browser(s) name and version -- : Google Chrome 51.0.2704.103 (64-bit)
I have to import customers from an external database into the #__hikashop_user (with custom fields) and the joomla #__users table from my own made component.
Is there an available method for this
or
Can I simply use a query agains #__hikashop_user table.
-- Víctor
Please Log in or Create an account to join the conversation.
10 years 2 months ago #246432
by nicolas
Replied by nicolas on topic Import users from an external database
Hi,
How are you going to generate the password in the Joomla user table with the format corresponding to Joomla ?
That's the big question here.
The HikaShop part is the easy part. You'll just need an update query to add the hikashop_user rows with the user id coming from the joomla user table and the custom fields data coming from your component data.
How are you going to generate the password in the Joomla user table with the format corresponding to Joomla ?
That's the big question here.
The HikaShop part is the easy part. You'll just need an update query to add the hikashop_user rows with the user id coming from the joomla user table and the custom fields data coming from your component data.
The following user(s) said Thank You: PeterChain
Please Log in or Create an account to join the conversation.
- PeterChain
-
Topic Author
- Offline
Less
More
- Posts: 640
- Thank you received: 16
10 years 2 months ago #246448
by PeterChain
Well, my option was to use the function register() on the UsersModelRegistration and use the id returning from the function to make an insert to the #__hikashop_users table, but i didn't know if i can do it from this way or there's a function in Hikashop that allows you to do it.
-- Víctor
Replied by PeterChain on topic Import users from an external database
nicolas wrote: Hi,
How are you going to generate the password in the Joomla user table with the format corresponding to Joomla ?
That's the big question here.
The HikaShop part is the easy part. You'll just need an update query to add the hikashop_user rows with the user id coming from the joomla user table and the custom fields data coming from your component data.
Well, my option was to use the function register() on the UsersModelRegistration and use the id returning from the function to make an insert to the #__hikashop_users table, but i didn't know if i can do it from this way or there's a function in Hikashop that allows you to do it.
-- Víctor
Please Log in or Create an account to join the conversation.
10 years 2 months ago #246461
by nicolas
Replied by nicolas on topic Import users from an external database
Hi,
Well, there is the save function of the class.user of HikaShop, to do it, but in your case, doing a simple insert in MySQL will do the same and will be simpler to implement so I would go with the insert.
Well, there is the save function of the class.user of HikaShop, to do it, but in your case, doing a simple insert in MySQL will do the same and will be simpler to implement so I would go with the insert.
Please Log in or Create an account to join the conversation.
Time to create page: 0.176 seconds