updated the query for password