Open Source Tutorials - Open Source Training
Open source training & tutorials from experienced, passionate people
chrome icon firefox icon ie icon opera icon safari icon Sings in these Browsers
A- A A+

By A Web Design

pdf icons

Lesson 5a - Hands on Exercises

  • 1. Create the ‘customer_master’ table with the following definition in the BANK_DB database which you have created in the previous lesson.

Set cust_id as Primary key while creating the table.

This table will hold the customer information.

Column Name Data Type Size
cust_id Int 10
cust_name Varchar 20
date_created Date  
opening_balance Float 10,2
  • 2. Create the ‘customer_detail’ table with the following definition in the BANK_DB database which you have created in the previous lesson.

Set cust_id of customer_Detail as Foreign key referencing the cust_id in the customer_master table while creating the table.

This table will hold the customer information in details.

Column Name Data Type Size
cust_id Int 10
permanentaddr Varchar 35
offaddr1 Varchar 35
offaddr2 Varchar 35
pincode Int 6
landlineno Double  
mobileno Double  
offtelephone Double  
  • 3. Create the ‘transaction_detail’ table with the following definition in the TRANSACTION_DB database which you have created in the previous lesson.

Set transaction_id as Primary Key and cust_id as Foreign Key referencing the cust_id in the customer_master table.

This table holds the transaction details of the customer.

Column Name Data Type Size
cust_id Int 10
transaction_id Int 15
name Varchar 15
chequeno Int 10
amount_deposit Float 10,2
amount_withdrawn Float 10,2
running_balance Float 10,2
dated Date