384 Part I EXAM PREPARATION APPLY YOUR KNOWLEDGE

384 Part I EXAM PREPARATION APPLY YOUR KNOWLEDGE begin update Employees set Status .= Part where current of FixStatus fetch next from FixStatus into @ID, .@Status end B. declare cursor FixStatus for SELECT ID, .Status from employees for update of .status declare @ID int, @Status varchar(4) fetch next from FixStatus into @ID, .@Status while @@FETCH_STATUS = 0 begin update Employees set .Status = Part where .current of .FixStatus fetch next from .FixStatus into .@ID, @Status end close FixStatus Deallocate FixStatus C. begin transaction declare cursor FixStatus for SELECT ID, .Status from employees for update of .status declare @ID int, @Status varchar(4) fetch next from FixStatus into @ID, .@Status while @@FETCH_STATUS = 0 begin update Employees set .Status = Part where .current of .FixStatus fetch next from .FixStatus into .@ID, @Status end close FixStatus Deallocate FixStatus commit transaction D. update employee set status = full 11. What is the value of @@TRANCOUNT after this code is run? begin transaction OuterTransaction insert into MyTable (2, 3, 19, . hello ) save transaction innertransaction insert into MyTable (2, 3, .37, goodbye ) rollback transaction innertransaction A. -1 B. 0 C. 1 D. 2 12. You are a database administrator at a small corporation. You ve just been asked to run a stored procedure, but you re wary because the last time someone did this, it caused massive lock contention and forced a system shutdown. What is printed by the following stored procedure? begin transaction declare @foo int select @foo = id from mytable print @foo rollback transaction A. Nothing. B. There are no database changes to the database, so this causes an error. C. It prints the value of @Foo. D. It prints the value of @Foo twice because of the rollback. 13. You re an administrator of a SQL Server 2000 server. You re hearing complaints from users about their applications hanging, occasionally receiving error messages. You ve found a couple of

For high quality java hosting services please check java web hosting website.

Comments are closed.