Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

What is a view? is View updatable?

Answer Posted / 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



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

as a general practice, it is recommended to have dbo be the owner of all database objects however, in your database you find number of tables owned by a user other than dbo, how could you fix this? : Sql server administration

915


Write a program using SQL queries to find a unique entry in a table.

943


How to maintain a fill factor in existing indexes?

945


What part does database design plays a role in performance of an sql server-based application?

928


How is a full-text index updated?

900


What are clustered and non-clustered index?

950


What is “begin trans”, “commit tran”, “rollback tran” and “savetran”?

964


Do you know what is similarity and difference between truncate and delete in sql?

961


Why truncate is ddl command?

995


what are the disadvantages of cursors? : Sql server database administration

974


Which tcp/ip port does the sql server run on? How can it be changed?

996


How to locate and take substrings with charindex() and substring() functions?

949


What is transaction server implicit?

949


What are the filtered indexes?

978


Can we insert data if clustered index is disabled?

893