I need some help on how to set up a database for user accounts on a mobile device. I have 2 tables: login and settings.
login
id 1
username test
password pass
settings
id(same key from login) 1
setting1 0
setting2 0
setting3 0
I have a register page and I want to insert the username, password, and an auto increment primary ID into the login table and I want to insert that same login ID, setting1, setting2, setting3 into the settings table. Can anyone give an example query on how to insert the login ID into both tables at the same time? How do people in the field normally set up user account databases? I will be using web-sql, but you can answer using any sql driver or just plain charts/text.