This topic is locked
[SOLVED]

 Admin is unable to add user - Duplicate primary key error

7/24/2013 4:27:50 PM
PHPRunner General questions
T
Tayyab Ilyas author

Hi
I have two users, Admin & Default/client
I want user to see and edit their own data and admin to see and add/edit all data
I have selected following settings
In Advance User settings i chose " User can edit and see their own data" and then in permission i have set admin to see/edit all data but when i try to add new user through admin user it give me Duplicate Primary Key Error.
If i change advance settings to "Users can edit and see other users data" then it works find but i dont want to do that
What is wrong here how can i solve this issue.
Thanks

J
Jeroef 7/24/2013

You need to check your database design. If you dont have already create a owner field and choose that field in settings instead of primary key field.
Ex.

FieldID (primary key field)

FieldownerID (owner field)



Hi
I have two users, Admin & Default/client
I want user to see and edit their own data and admin to see and add/edit all data
I have selected following settings
In Advance User settings i chose " User can edit and see their own data" and then in permission i have set admin to see/edit all data but when i try to add new user through admin user it give me Duplicate Primary Key Error.
If i change advance settings to "Users can edit and see other users data" then it works find but i dont want to do that
What is wrong here how can i solve this issue.
Thanks

T
Tayyab Ilyas author 7/30/2013

Thanks issue solved.