Fórum

Database for New User

Iseng Dong, modificado 11 Anos atrás.

Database for New User

New Member Postagens: 11 Data de Entrada: 25/04/12 Postagens Recentes
Hi guys....
I am using Liferay 6.1.

I would like to ask something.
When you create a new user from Liferay control panel, which tables get effected in liferay's database?
Well, I figured out something. There are 6 tables according to what I could see. There are: users_groups ; users_roles ; contact_ ; user_ ; assetEntry ; resourcePermission.
Is there any other tables that get affected.

Oh... and by the way, I am asking this because I want to add a user manually into Liferay database. Well, I did ask and try the solution given from here: http://www.liferay.com/community/forums/-/message_boards/message/13635690 ; but, no luck until now emoticon

Thank you for helping me........ emoticon
thumbnail
David H Nebinger, modificado 11 Anos atrás.

RE: Database for New User

Liferay Legend Postagens: 14917 Data de Entrada: 02/09/06 Postagens Recentes
Don't do it, it's a trap...

The API is the only blessed way to add a user. It's the only way to ensure that all tables are updated appropriately. There's also indexing to consider, which cannot be done using a direct query.

Just don't do it.
Iseng Dong, modificado 11 Anos atrás.

RE: Database for New User

New Member Postagens: 11 Data de Entrada: 25/04/12 Postagens Recentes
David H Nebinger:
Don't do it, it's a trap...

The API is the only blessed way to add a user. It's the only way to ensure that all tables are updated appropriately. There's also indexing to consider, which cannot be done using a direct query.

Just don't do it.



But, I need to do it. Because, I am trying to transfer users data from other website's database which doesn't use Liferay. I have no choice but to insert it inside database.
Well, do you have any suggestions????
Iseng Dong, modificado 11 Anos atrás.

RE: Database for New User

New Member Postagens: 11 Data de Entrada: 25/04/12 Postagens Recentes
anyone???????? please?????
thumbnail
David H Nebinger, modificado 11 Anos atrás.

RE: Database for New User

Liferay Legend Postagens: 14917 Data de Entrada: 02/09/06 Postagens Recentes
Yep, the user service is available as a web service which you can use the portal-client.jar to access. Create a simple java process to retrieve the users from the other database, marshal the information into the appropriate formats, then use the UserServiceSoap interface to add the user to Liferay using the web services.
Iseng Dong, modificado 11 Anos atrás.

RE: Database for New User

New Member Postagens: 11 Data de Entrada: 25/04/12 Postagens Recentes
David H Nebinger:
Yep, the user service is available as a web service which you can use the portal-client.jar to access. Create a simple java process to retrieve the users from the other database, marshal the information into the appropriate formats, then use the UserServiceSoap interface to add the user to Liferay using the web services.



Can you explain in more details, please? I am still new with Liferay emoticon
thumbnail
Hitoshi Ozawa, modificado 11 Anos atrás.

RE: Database for New User

Liferay Legend Postagens: 7942 Data de Entrada: 24/03/10 Postagens Recentes
You can also develop a portlet to read data from a file and to import it into liferay.
Use UserLocalServiceUtil.addUser() method to insert user.
http://docs.liferay.com/portal/6.0/javadocs/com/liferay/portal/service/UserLocalServiceUtil.html
Gowtham Mani, modificado 11 Anos atrás.

RE: Database for New User

Junior Member Postagens: 56 Data de Entrada: 26/11/08 Postagens Recentes
If you are trying to add the user from external java applications you can use the Portal_UserService to add the user.