Vista combinada Visión Plana Vista de árbol
Discusiones [ Anterior | Siguiente ]
toggle
How to insert data in User table through own portlet ?? piyush liferay 30 de enero de 2013 2:54
RE: How to insert data in User table through own portlet ?? Siby Mathew 30 de enero de 2013 3:23
RE: How to insert data in User table through own portlet ?? Hitoshi Ozawa 30 de enero de 2013 3:37
RE: How to insert data in User table through own portlet ?? piyush liferay 30 de enero de 2013 4:12
RE: How to insert data in User table through own portlet ?? Jitendra Rajput 30 de enero de 2013 4:14
RE: How to insert data in User table through own portlet ?? Hitoshi Ozawa 30 de enero de 2013 4:19
RE: How to insert data in User table through own portlet ?? piyush liferay 30 de enero de 2013 4:25
RE: How to insert data in User table through own portlet ?? Hitoshi Ozawa 30 de enero de 2013 4:30
RE: How to insert data in User table through own portlet ?? piyush liferay 30 de enero de 2013 4:35
RE: How to insert data in User table through own portlet ?? Hitoshi Ozawa 30 de enero de 2013 4:40
RE: How to insert data in User table through own portlet ?? piyush liferay 30 de enero de 2013 4:46
RE: How to insert data in User table through own portlet ?? Siby Mathew 30 de enero de 2013 4:50
RE: How to insert data in User table through own portlet ?? piyush liferay 30 de enero de 2013 4:52
RE: How to insert data in User table through own portlet ?? Hitoshi Ozawa 30 de enero de 2013 5:00
RE: How to insert data in User table through own portlet ?? Bharamani P Tashildar 5 de julio de 2015 22:19
RE: How to insert data in User table through own portlet ?? Harish Kumar 5 de julio de 2015 23:23
RE: How to insert data in User table through own portlet ?? Bharamani P Tashildar 6 de julio de 2015 2:33
piyush liferay
How to insert data in User table through own portlet ??
30 de enero de 2013 2:54
Respuesta

piyush liferay

Ranking: Junior Member

Mensajes: 40

Fecha de incorporación: 1 de enero de 2013

Mensajes recientes

Hello ,

How to insert data in User table which is already present in liferay..

can you suggest me best solution for that...
Siby Mathew
RE: How to insert data in User table through own portlet ??
30 de enero de 2013 3:23
Respuesta

Siby Mathew

Ranking: Expert

Mensajes: 267

Fecha de incorporación: 4 de marzo de 2011

Mensajes recientes

Use methods from UserLocalServiceUtil.java like addUser, updateUser etc.

Thanks,
Siby
Hitoshi Ozawa
RE: How to insert data in User table through own portlet ??
30 de enero de 2013 3:37
Respuesta

Hitoshi Ozawa

Ranking: Liferay Legend

Mensajes: 7949

Fecha de incorporación: 23 de marzo de 2010

Mensajes recientes

Use UserLocalServiceImpl.addUser

http://docs.liferay.com/portal/6.1/javadocs-all/com/liferay/portal/service/impl/UserLocalServiceImpl.html

OR

UserLocalServiceUtil.AddUser

http://docs.liferay.com/portal/6.1/javadocs/com/liferay/portal/service/UserLocalServiceUtil.html
piyush liferay
RE: How to insert data in User table through own portlet ??
30 de enero de 2013 4:12
Respuesta

piyush liferay

Ranking: Junior Member

Mensajes: 40

Fecha de incorporación: 1 de enero de 2013

Mensajes recientes

Hitoshi Ozawa:
Use UserLocalServiceImpl.addUser

http://docs.liferay.com/portal/6.1/javadocs-all/com/liferay/portal/service/impl/UserLocalServiceImpl.html

OR

UserLocalServiceUtil.AddUser

http://docs.liferay.com/portal/6.1/javadocs/com/liferay/portal/service/UserLocalServiceUtil.html


Liferay User Class contain some of few fields but i have more fields so i have to insert some field in User Class and Some Field in Own Class..

so how to insert such entries in both the User and Own class.

Thanks..
Jitendra Rajput
RE: How to insert data in User table through own portlet ??
30 de enero de 2013 4:14
Respuesta

Jitendra Rajput

Ranking: Liferay Master

Mensajes: 873

Fecha de incorporación: 7 de enero de 2011

Mensajes recientes

For the extra fields you can create custom fields .
http://www.liferay.com/community/wiki/-/wiki/Main/Custom+fields
Hitoshi Ozawa
RE: How to insert data in User table through own portlet ??
30 de enero de 2013 4:19
Respuesta

Hitoshi Ozawa

Ranking: Liferay Legend

Mensajes: 7949

Fecha de incorporación: 23 de marzo de 2010

Mensajes recientes

For you own fields, just use expando

http://www.liferay.com/community/wiki/-/wiki/Main/Developing+with+Expando
piyush liferay
RE: How to insert data in User table through own portlet ??
30 de enero de 2013 4:25
Respuesta

piyush liferay

Ranking: Junior Member

Mensajes: 40

Fecha de incorporación: 1 de enero de 2013

Mensajes recientes

can we insert data without using expando ??
Hitoshi Ozawa
RE: How to insert data in User table through own portlet ??
30 de enero de 2013 4:30
Respuesta

Hitoshi Ozawa

Ranking: Liferay Legend

Mensajes: 7949

Fecha de incorporación: 23 de marzo de 2010

Mensajes recientes

can we insert data without using expando ??


Insert data where? You need a database table column to enter data. Which column do you want to enter you data?
piyush liferay
RE: How to insert data in User table through own portlet ??
30 de enero de 2013 4:35
Respuesta

piyush liferay

Ranking: Junior Member

Mensajes: 40

Fecha de incorporación: 1 de enero de 2013

Mensajes recientes

i have column for inserting a data but not using expando..

i am inserting a data normally ..

can we insert data in database ??
Hitoshi Ozawa
RE: How to insert data in User table through own portlet ??
30 de enero de 2013 4:40
Respuesta

Hitoshi Ozawa

Ranking: Liferay Legend

Mensajes: 7949

Fecha de incorporación: 23 de marzo de 2010

Mensajes recientes

have column for inserting a data but not using expando..


So, use your api to enter data into your column. I'm not sure what the problem is. If you created a column, creating a method to insert/change/delete data from that column is dependent on you code not liferay's.
piyush liferay
RE: How to insert data in User table through own portlet ??
30 de enero de 2013 4:46
Respuesta

piyush liferay

Ranking: Junior Member

Mensajes: 40

Fecha de incorporación: 1 de enero de 2013

Mensajes recientes

Hitoshi Ozawa:
have column for inserting a data but not using expando..


So, use your api to enter data into your column. I'm not sure what the problem is. If you created a column, creating a method to insert/change/delete data from that column is dependent on you code not liferay's.



Sir i write down my complete problem here ....

i have fileds like :-

name,email,password,mobileno,address etc.

but in User class contain only name,email and password field so i want to insert mobileno and address field in my class Register

so give me the solution for that problem... but i am not using a expando.
Siby Mathew
RE: How to insert data in User table through own portlet ??
30 de enero de 2013 4:50
Respuesta

Siby Mathew

Ranking: Expert

Mensajes: 267

Fecha de incorporación: 4 de marzo de 2011

Mensajes recientes

Hi Piyush,
The easiest way to achieve this is to store it in the expando.
But if you really want another table, use servicebuilder to generate a new table. All the CRUD operations will be autogenerated by Liferay.
After inserting the user, you can use these APIs to update your custom table.

Thanks,
Siby
piyush liferay
RE: How to insert data in User table through own portlet ??
30 de enero de 2013 4:52
Respuesta

piyush liferay

Ranking: Junior Member

Mensajes: 40

Fecha de incorporación: 1 de enero de 2013

Mensajes recientes

but for inserting a user i want to require a userId which is autoincrement so how can i do ...
Hitoshi Ozawa
RE: How to insert data in User table through own portlet ??
30 de enero de 2013 5:00
Respuesta

Hitoshi Ozawa

Ranking: Liferay Legend

Mensajes: 7949

Fecha de incorporación: 23 de marzo de 2010

Mensajes recientes

but for inserting a user i want to require a userId which is autoincrement so how can i do ...


The subject of this thread has nothing to do with the question you're asking now.
Close this thread and create a new thread with the question you've just asked - "How to modify liferay addUser method to autoincrement userId"
Bharamani P Tashildar
RE: How to insert data in User table through own portlet ??
5 de julio de 2015 22:19
Respuesta

Bharamani P Tashildar

Ranking: Junior Member

Mensajes: 35

Fecha de incorporación: 27 de agosto de 2014

Mensajes recientes

HI friends,,

The same problem i am facing...

for user_ there are two methods available that we can use

1.. UserLocalServiceUtil.addUser(user);
2..UserLocalServiceUtil.addUser(creatorUserId, companyId, autoPassword, password1, password2, autoScreenName, screenName,
emailAddress, facebookId, openId, locale, firstName, middleName, lastName, prefixId, suffixId, male,
birthdayMonth, birthdayDay, birthdayYear, getTitle(null), groupIds, organizationIds, roleIds,
userGroupIds, sendEmail, serviceContext);

Both i tried but no result plz help me to solve this..............

I have firstName ,lastName, password, emailId, role and autogenerated userId in my custom portlet......
I want to store it in User_table

Thanks & Regards
Bharamani Tashildar
Harish Kumar
RE: How to insert data in User table through own portlet ??
5 de julio de 2015 23:23
Respuesta

Harish Kumar

Ranking: Expert

Mensajes: 474

Fecha de incorporación: 31 de julio de 2010

Mensajes recientes

Hi

Data should be saved in user_ table. Following is the code snippet you can try

 1
 2user = UserLocalServiceUtil.addUser(themeDisplay.getUserId(),
 3                    themeDisplay.getCompanyId(), false, password, password, false,
 4                    screenName, email, 0L, StringPool.BLANK,
 5                    themeDisplay.getLocale(), firstName, StringPool.BLANK, lastName, 0, 0,
 6                    true, 1, 1, 1971, StringPool.BLANK,
 7                    new long[] { themeDisplay.getScopeGroupId() },
 8                    new long[] {}, new long[] {}, new long[] {}, false,
 9                    serviceContext);
Bharamani P Tashildar
RE: How to insert data in User table through own portlet ??
6 de julio de 2015 2:33
Respuesta

Bharamani P Tashildar

Ranking: Junior Member

Mensajes: 35

Fecha de incorporación: 27 de agosto de 2014

Mensajes recientes

Thank s Harish Sir
Its working Fine