Assignment 3
Assignment 3
/* 1. Create a stored procedure to display the restaurant name, type and cuisine
where the
table booking is not zero.*/
exec table_Booking
/*2. Create a transaction and update the cuisine type �Cafe� to �Cafeteria�. Check
the result
and rollback it.*/
Begin transaction
update Jomato
set CuisinesType = 'Cafeteria' where CuisinesType = 'Cafe'
Rollback Transaction
/*3. Generate a row number column and find the top 5 areas with the highest rating
of
restaurants. */
select top 5
DENSE_RANK ()over (order by rating desc) as Row_Number, Area
from Jomato
/* 5. Write a query to Create a Top rating view to store the generated top 5
highest rating of
restaurants. */