You can use the sql statement to find the duplicate entry in the database.
For example if you have user table with a field called login_id and you want to find if the user exists in the database then you can use the following query:
select * from user where login_id='loginidtobechecked';
and query it in database. Here you replace 'loginidtobechecked' with the login id you are checking.
This way you will be able to find the duplicate.
Similar concepts apply to all other tables in the database.