What is a view? is View updatable?
Answers were Sorted based on User's Feedback
Answer / neetu
a view is a virtual table.it's an object that derives it's
data from one or more tables.it ensures that users are able
to retrieve and modify only the data which is seem by them.
u r unable to update attributes becoz views allow only one
of the underlying tables to be updated at a time.u need to
update attributes by giving two separate update commands.
Is This Answer Correct ? | 24 Yes | 8 No |
Answer / harinireddy
view is a virtual table created from the physical table
which is existing.view can be updated unless the base table
does not have any relation u another table
Is This Answer Correct ? | 14 Yes | 4 No |
Answer / sandhya
You can modify data by using a view in only one of its base
tables even though a view may be derived from multiple
underlying tables. For example, a view vwNew that is
derived from two tables, table and table2, can be used to
modify either table or table2 in a single statement. A
single data modification statement that affected both the
underlying tables is not permitted
Is This Answer Correct ? | 9 Yes | 1 No |
Answer / kumaran
A view is a Virtual Table or a Logical representation.
View type :- SimpleView and Complex View.
Simple views are updatable.
Is This Answer Correct ? | 8 Yes | 1 No |
Answer / suraj
-- Views are updatable regardless of the number of
tables involved in that view.
-- Data contained in the base tables are updated when
VIEWS are updated.
drop table t1
drop table t2
drop view t1t2
create table t1(ID int, FirstName varchar(20))
create table t2(ID int, LastName varchar(20))
insert t1 values(1,'John')
insert t1 values(2,'Mike')
insert t2 values(1,'Smith')
insert t2 values(2,'Shres')
create view t1t2
as
select t1.FirstName, t2.LastName
from t1 inner join t2 on t1.ID=t2.ID
update t1t2
set FirstName='Steve' where LastName='Smith'
select * from t1t2
select * from t1
Is This Answer Correct ? | 12 Yes | 6 No |
Answer / kalyana chakravarthy
View is a taliored representation of data of a particular
table. In one way to say view is a shadow of a table. What
ever U do on a view will reflect on the table vice versa.
Views r 2 types simple and complex simple is selected rows
from one table and complex is selected from more than one.
In oracle complex view can be updated by using instead of
triggers from version 8.0
Is This Answer Correct ? | 5 Yes | 1 No |
Answer / sai krishna.k
a view is nothing but a logical representation of tables.
it is also called as "virtual table".
a view may be updatable view or non updatable view.
Is This Answer Correct ? | 7 Yes | 4 No |
Answer / darshan shah
View is sub set of one or more then one tables
View is use to fetch the selected columns from one more
then one tables.
Yes we can update the view if it is not read only.
Is This Answer Correct ? | 3 Yes | 1 No |
Answer / venkat
view is a virtual table i.e a new table is created using
base table.
view can be updated based on some restrictions
Is This Answer Correct ? | 3 Yes | 1 No |
Answer / amit upadhyay
VIEW :- VIEW IS VIRTUAL TABLE. WHICH GIVE ACCESS TO SUBSET
OF COLUMN OF THE TABLES.
VIEW CAN BE UPDATED THAT GET EFFECTED THE TABLE ALSO.
Is This Answer Correct ? | 2 Yes | 1 No |
How to insert multiple rows with a subquery?
Explain cursor as data base object?
How to return the date part only from a sql server datetime datatype?
What is difference between aggregate and analytic function?
How many types of relations are there between dimension and measure group? : sql server analysis services, ssas
What is the new security features added in sql server 2016? : sql server security
What is a SQL Server Temporary Table?
How to verify a login name with sqlcmd tool?
What is the use of @@spid?
How to set database to be read_only in ms sql server?
Why should we go for stored procedures? Why not direct queries?
What the different types of Replication and why are they used?