var sidebar_align = 'right';
var content_container_margin = parseInt('290px');
var sidebar_width = parseInt('270px');
Unanswered: SQL Query Copy Columns
One user registers, his name goes to one table several times like this
user | categories
(column user value "name" is the same for all rows)
then in another table i have the same number of categories as the name values inserted
I want to UPDATE table one and insert each category to the name and the result would be
name | category
Is there a way to do that?
this is an unnecessary step
Originally Posted by MrCapuchino
instead of multiple inserts followed by an update, you can do it all in one step like this --
I was doing it all wrong
After talking with a professional programmer he told me that I was doing everything the wrong way,
What I want to do is best done with FOREIGN KEYS, I did not know how to use them but now I'm understanding how they work and I totally need them to do what I want in my application.
That's why all the answers from other people did not worked because they thought I already was managing foreign keys.
Thanks everyone for the help!