xCREATE TABLE Customers (
CustomerID INT PRIMARY KEY AUTO_INCREMENT,
FirstName VARCHAR(100) NOT NULL,
LastName VARCHAR(100) NOT NULL,
Email VARCHAR(100) UNIQUE,
Phone VARCHAR(15),
DateOfBirth DATE,
JoinDate DATE NOT NULL
);
-- Create the Accounts Table
CREATE TABLE Accounts (
AccountID INT PRIMARY KEY AUTO_INCREMENT,
CustomerID INT,
AccountType VARCHAR(50) NOT NULL,
Balance DECIMAL(10, 2) NOT NULL DEFAULT 0.00,
OpenDate DATE NOT NULL,
FOREIGN KEY (CustomerID) REFERENCES
);
-- Create the Transactions Table
CREATE TABLE Transactions (
TransactionID INT PRIMARY KEY AUTO_INCREMENT,
AccountID INT,
TransactionDate DATE NOT NULL,
Amount DECIMAL(10, 2) NOT NULL,
TransactionType VARCHAR(20) NOT NULL,
Description VARCHAR(255),
FOREIGN KEY (AccountID) REFERENCES Accounts(AccountID)
);
To embed this program on your website, copy the following code and paste it into your website's HTML: