trigger --update (correct value)

  • tblContact [PK contId(int 4), Name, MemoCount(int 4)]

    tblMemo[pk memoId (int 4), {FK} contId(int 4), memo (varchar 100)]

    I need to Write a trigger to automatically update the MemoCount field in the tblContact whenever a memo is inserted, updated or deleted. Assuming Assuming that the memoCount field have the correct value.

    Edited by - mark00189 on 05/13/2003 2:42:08 PM

  • I just responded to your other one and realized that you also need to join to either the "inserted" or "deleted" table when you do your update to tblContacts so only the correct row is updated.

    Darren


    Darren

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply