Answer Posted / sanjeev kumar
CREATE VIEW Authorsview
AS
SELECT au_id, au_fname, au_lname, phone, state, contract
FROM authors
WHERE state = 'ca'
This is an updatable view and a user can change any column value
like:
UPDATE Authorsview SET state='NY'
Example: but when we create With Check Option then Same as
above but the state column cannot be changed.
CREATE VIEW Authorsview
AS
SELECT au_id, au_fname, au_lname, phone, state, contract
FROM authors
WHERE state = 'ca'
With Check Option
The view is still updatable, except for the state column:
UPDATE Authorsview SET state='NY'
This will cause an error and the state will not be changed
because we have use check option with state.
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
How can you hide the sql server instances?
What is single-user mode?
How to install sql server 2005 express edition?
How to modify existing triggers using "alter trigger"?
What is single-user mode and what are the steps you should follow to start sql server in single-user mode?
How to check parameter value in stored procedure sql server?
Can we write ddl in trigger?
How real and float literal values are rounded?
Can a unique index be created on a column, which contains null?
What is SQL Server?
What are the different types of replication are there in sql server 2000?
What do you mean by normalisation?
When would you use it?
What is function of ROLLUP ?
what method you can use to reduce the overhead of Reporting Services data sources?