save user info into database