Hey, I hope this is something simple but I'm already over my head (but making progress ... yeayyyy). Anyway, here's a link to my previous thread (which contains the data schema and sample data): [url]http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=77319[/url].I've got the update part working but I am having a heck of a time getting the program to insert all newsletters for employees not currently in the newsletter list. Anyway, here is the query I'm trying to run:insert into tblEmpLet ( empID, nletID, nlfID ) select distinct e.empID, (SELECT el.nletID, el.nlfID FROM tblEmpLet WHERE empID = @in_intEmpID) from tblEmployee e left join tblEmpLet el on e.empID = el.empID where el.empID is null
but it gives me this error:quote:
The select list for the INSERT statement contains fewer items than the insert list. The number of SELECT values must match the number of INSERT columns