I can't get the following Insert to work although the syntax seems correct..
INSERT INTO views T
JOIN members T2
ON '$username' = T2.username
(ITEM_ID, ITEM_TYPE, USER_ID, USER_TYPE)
VALUES('$itemview', '$type', T2.id, '$usertype')
All the variables are predefined of course..
What am I doing wrong here?
The Error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'T JOIN members T2 ON 'testuser' = T2.username (ITEM_ID, IT' at line 1