Vista combinada Visión Plana Vista de árbol
Discusiones [ Anterior | Siguiente ]
toggle
Rahul Chaturvedi
import users into liferay database by sql import statements
26 de marzo de 2009 1:04
Respuesta

Rahul Chaturvedi

Ranking: New Member

Mensajes: 6

Fecha de incorporación: 26 de marzo de 2009

Mensajes recientes

We need to create a batch process which would run separately and will import the users from an external system into liferay.
1. What we want is to create sql import statements that will insert the data into liferay database (we have pointed liferay 5.1.2 to a MySQL database) And then the users should be become the part of this liferay.

Could you please let me know what all tables needs to be updated for the same. As there must be multiple tables that needs to be updated if we import a user (one of them is User_ )
We would like to know the sql statements by which we can accomplish this.

2. Another information we require to know is how can this aforementioned import be done so that user is able to login in liferay with the same password present in external system. So in the sql statements do we need to give the cleartext value or encrypted value. Since we want liferay to save passwords in encrypted format so the security concern is addressed.
Manish Kumar Gupta
RE: import users into liferay database by sql import statements
26 de marzo de 2009 2:55
Respuesta

Manish Kumar Gupta

LIFERAY STAFF

Ranking: Liferay Master

Mensajes: 535

Fecha de incorporación: 15 de mayo de 2008

Mensajes recientes

I am just giving you another approach. Since, you are fetching data from an external system, you can use Liferay API to create users. This way, you will not be required to write SQL statements, no password security concern and no need to know what all tables are involved.

My 2 cents.
Rahul Chaturvedi
RE: import users into liferay database by sql import statements
26 de marzo de 2009 4:39
Respuesta

Rahul Chaturvedi

Ranking: New Member

Mensajes: 6

Fecha de incorporación: 26 de marzo de 2009

Mensajes recientes

Thanks Manish for your suggestion.

What we want is a separate batch process to take care of user imports. So creation of users using APIs in a batch would also do.

Could you please let me know the APIs (path to API) or sample code in case you have to which can take care of the task I want to achieve.
Manish Kumar Gupta
RE: import users into liferay database by sql import statements
26 de marzo de 2009 7:47
Respuesta

Manish Kumar Gupta

LIFERAY STAFF

Ranking: Liferay Master

Mensajes: 535

Fecha de incorporación: 15 de mayo de 2008

Mensajes recientes

See this file to get an idea on creating user by using LR api.

Let me know if you need any help.
Anónimo
RE: import users into liferay database by sql import statements
14 de octubre de 2009 11:38
Respuesta

Anónimo

Hello manish,
I have the same need, could you please explain how to use this patch to import users using liferay API. this is an emergency please
Thanks
Lisa Simpson
RE: import users into liferay database by sql import statements
19 de octubre de 2009 8:56
Respuesta

Lisa Simpson

Ranking: Liferay Legend

Mensajes: 2034

Fecha de incorporación: 5 de marzo de 2009

Mensajes recientes

Manesh,

This really belongs in the Wiki!!
Richard Sezov
RE: import users into liferay database by sql import statements
19 de octubre de 2009 9:31
Respuesta

Richard Sezov

LIFERAY STAFF

Ranking: Regular Member

Mensajes: 201

Fecha de incorporación: 7 de febrero de 2007

Mensajes recientes

You can use Liferay's web services to insert users. This approach has been taken by many users.

Please see the Liferay Portal Administrator's Guide, pp 244-247 for instructions on accessing Liferay's web services. You can generate a client from the WSDL very easily using any modern IDE (I've done it on both Eclipse and NetBeans) or Apache's wsdl2java utility. From there, just call the web service via a batch process whenever you want to insert a user.
Alistair Oldfield
RE: import users into liferay database by sql import statements
5 de octubre de 2011 2:42
Respuesta

Alistair Oldfield

Ranking: New Member

Mensajes: 1

Fecha de incorporación: 21 de febrero de 2011

Mensajes recientes

Hello,

We are also facing this issue, but using the API will not be enough. We are importing close to 1M users and this will take days.
Has anyone managed to accomplish this import using direct SQL statements (safely) into the DB?