[dba-SQLServer] View not updatable because

jwcolby jwcolby at colbyconsulting.com
Wed Oct 28 11:31:50 CDT 2009


I have never figured out how to do the following...

I have a table which contains records that I need to delete.  I create a view that joins that table 
to another table on the PKID.  The second table has a set of records which I need to delete out of 
the first table, then append into the first table.  IOW the matching records in the first table have 
have been updated and I need to delete them, then append in the updated records.

I get an error message:

"view or function MyFunction is not updatable because the modification affects multiple base tables."

This is a simple view witj two tables, joined on the PKID, all fields selected in the table that 
needs records updated (deleted), NO fields selected in the second table.

What am I doing wrong?

-- 
John W. Colby
www.ColbyConsulting.com



More information about the dba-SQLServer mailing list