score:1

As mentioned in comments on question, it is probably better to put your inserts into a transaction in the stored proc already called, but if you must do a trigger, this is about what it should look like. Note the specific name and then the insert being done from the INSERTED table.

ALTER TRIGGER UserProfile_CreateUser
ON  dbo.UserProfile
FOR INSERT
AS
BEGIN
    INSERT dbo.Users (UserID)
        SELECT ProfileID
        FROM INSERTED
END
GO

For more info on virtual tables: http://msdn.microsoft.com/en-us/library/ms191300.aspx


More questions

More questions with similar tag