I would like to add records to table AppointmentContact using a subquery as well as pass in a value for ContactID. THis is what I have so far:
INSERT INTO dbo.AppointmentContact (
AppointmentID, ContactID )
(SELECT a.AppointmentID
FROMdbo.Appointment a
WHERE
a.AppointmentTypeID=3
AND
a.SelectToFax = 1
AND
a.PartyID = 39546)
)
How can I do this?
Thanks,
Sam