Forums

Home » Liferay Portal » English » 2. Using Liferay » General

Combination View Flat View Tree View
Threads [ Previous | Next ]
toggle
Ricardo Vela
User Issue
April 17, 2012 2:49 PM
Answer

Ricardo Vela

Rank: Junior Member

Posts: 85

Join Date: April 14, 2010

Recent Posts

hi!

i have a weird issue with a user , well its not a user yet because when i try to create the user an error of duplicate username appears, but the users doesnt exist into the portal, i look for him (username) in user_ and contact_ tables and nothing!, i tried with rebuild search indexes but nothing happend... what else could it be?. where else the username can be found?


Regards
Hitoshi Ozawa
RE: User Issue
April 17, 2012 10:40 PM
Answer

Hitoshi Ozawa

Rank: Liferay Legend

Posts: 8000

Join Date: March 23, 2010

Recent Posts

What is the exact error you're getting. When liferay creates an user, it also creates default home pages (private and public), assign roles, and many other things. You've probably created and deleted some users from your programs without updating the other related entities. The user may not exists in the user_ table, but some remains probably are left over in other tables causing the duplicate entry error.

If this isn't production, better and easier to drop the database and create it again.
Ricardo Vela
RE: User Issue
April 18, 2012 7:39 AM
Answer

Ricardo Vela

Rank: Junior Member

Posts: 85

Join Date: April 14, 2010

Recent Posts

thanks for the answer

sadly it is in production :S ... but im going to look into the tables and try to find where the root of this issue


Regards
Hitoshi Ozawa
RE: User Issue
April 18, 2012 7:57 AM
Answer

Hitoshi Ozawa

Rank: Liferay Legend

Posts: 8000

Join Date: March 23, 2010

Recent Posts

I had a similar case on my production server too. First, I tried to find all the related records and tried deleting them, but it was getting complex tracing all the tables. However, I was lucky to have the deleted data on hand, so I activated the user back in by inserting the records. Once the records were back in place, I was able to delete the user from Control Panel. From there, I was able to just add the user again.
Ricardo Vela
RE: User Issue
May 9, 2012 11:01 AM
Answer

Ricardo Vela

Rank: Junior Member

Posts: 85

Join Date: April 14, 2010

Recent Posts

I found the solution to this problem. for if someone else have the same issue

I found that if user is not in user_ and contact_ table and have the com.liferay.portal.DuplicateUserScreenNameException. in here you can also find the user (for me it worked)

select * from group_ where creatoruserid not in(select userid from user_);

and then you can delete the user....



Regards