>Back to my example. I'm not entirely sure what this trigger is doing.
>
>
>CREATE TRIGGER InsertPublication
>ON Publications
>AFTER INSERT
>AS
>BEGIN
> UPDATE Books
> SET NumPublications = NumPublications + 1
> FROM Books, inserted
> WHERE Books.ISBN = inserted.ISBN
>END
>
>
For each inserted book information into the Publications table this trigger also updates Books table and increments NumPublications field.
In another words, say, you inserted two records into Publications table with the same ISBN, then Books table would have NumPublications field incremented by 2 for this Book.
If it's not broken, fix it until it is.
My Blog