I hope the subject was somewhat descriptive.
I'm trying to INSERT records into a table, easy...
My insert statement is as follows:
INSERT INTO user_tbl
SELECT * FROM user_tbl WHERE user_id IN (SELECT user_id FROM list_user_index_tbl WHERE list_id = 11)
This is simple. I'm inserting the users that are in list_id 11. Now I want to grab the new user_id's (IDENTITY FIELD) from the newly inserted users and use those values back in the list_user_index_tbl with a different list_id value. list_user_index_tbl has only two fields user_id and list_id.
Making any sense?
any help would be great!
josh
I'm trying to INSERT records into a table, easy...
My insert statement is as follows:
INSERT INTO user_tbl
SELECT * FROM user_tbl WHERE user_id IN (SELECT user_id FROM list_user_index_tbl WHERE list_id = 11)
This is simple. I'm inserting the users that are in list_id 11. Now I want to grab the new user_id's (IDENTITY FIELD) from the newly inserted users and use those values back in the list_user_index_tbl with a different list_id value. list_user_index_tbl has only two fields user_id and list_id.
Making any sense?
any help would be great!
josh