Question: Consider the Bank Database schema: branch ( branch _ name: string, branch _ city: string, assets: real ) account ( account _ number: integer, branch
Consider the Bank Database schema:
branch branchname: string, branchcity: string, assets: real
account accountnumber: integer, branchname: string, balance: real
depositor customername: string, accountnumber: integer, customercity: string
The key fields are underlined, and the domain of each field is listed after the field name. Therefore branchname is the key for branch, accountnumber is the key for account, and customername and accountnumber together form the key for depositor. The depositor relation lists the customer names for each account
Write the following queries in SQL
i List in alphabetic order the names of all customers having an account in Gandhinagar branch
ii Find all branches that have greater total account balance than Jayanagar branch
iii. Find all branches, of Bangalore city, which has an account of all the customers located in Bangalore.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
