You can only use `instead of` triggers on views, can you post your code please? [
http://msdn.microsoft.com/en-us/library/ms189799.aspx] > table | view Is the table or view on > which the DML trigger is executed and > is sometimes referred to as the > trigger table or trigger view. > Specifying the fully qualified name of > the table or view is optional. A view > can be referenced only by an INSTEAD > OF trigger. DML triggers cannot be > defined on local or global temporary > tables. :
A view is just a query. It's not a table on the database, although it appears to behave as one. @Fatherjack has already hit it, you can't create indexes or triggers, except INSTEAD OF triggers, on a view. You can't even create a clustered index ON a view. You can create a clustered index that references a view, this what is known as a materialized view or an indexed view. An indexed view is simply a view that has been processed, meaning, all it's data has been retrieved, and is stored within a clustered index. You need to be very careful when using these. They work well with slowly or unchanging data. If you have volatile data, they can be very problematic.