I'm using the codeigniter PHP framework to create a user login system with profile and what not.
I've currently got a register and login system, and a form to "edit profile data".
However, because of Foreign Key constraints between the account table and profile table, if they were to attempt to edit their profile again, it would be inserting data into the table, which can't be done because there can only be one profile table row per account.
I was wondering if the update function in MySQL will insert data if a row doesn't already exist? and then just update that row every single profile edit call.
Thanks for the help.