Professional Documents
Culture Documents
Description: Used to store client information Column Name CLIENTNO NAME ADDRESS1 ADDRESS2 CITY PINCODE STATE BALDUE Data Type Varchar2 Varchar2 Varchar2 Varchar2 Varchar2 Number Varchar2 Number Size 6 20 30 30 15 8 15 10,2 Attributes Primary Key / first letter must start with C Not Null
Insert the following data into their respective tables: ClientNo C00001 C00002 C00003 C00004 C00005 C00006 Name Anil Sachin Dravid Ganguly Sehwag Harbhjan City Madras Mumbai Mumbai Bangalore Banglore Jalandhar Pincode 780001 400054 400057 560001 560001 144401 State Tamil Nadu Maharashtr a Maharashtr a Karnataka Karnataka Punjab BalDue 15000 0 5000 7000 2000 0
6. Create a table Balance_Details from Client_Master with columns ClientNo, Name,City and BalDue) 7. Make the ClientNo in the Balance_Details table as the foreign key to the ClientNo in the Client_Master table. 8. Delete all the values from the Balance_Details table and then insert the values from Client_Master into the Balance_Details table. 9. List the city and the number of clients we have in city named Mumbai, Bangalore. 10.What is the total balance amount pending against the clients? 11.List the client details for the minimum and maximum balance amount pending against them. 12.List the average of the amount pending against the all the clients. 13.Create a view by selecting the baldue from the balance_details table and client_no, name from the client_master table. 14.Try to update the values in the view. 15.Permanenetly delete the view from the database.