0% found this document useful (0 votes)
11 views2 pages

Script 20SQL 20xampp

The document outlines a series of MySQL commands to create a database named 'ShopMS' and several tables including 'author', 'Book', 'Warehouse_book', 'Warehouse', 'Publisher', 'ShoppingBasket_Book', 'Customer', and 'Shoppingbasket'. Each table is defined with specific fields and data types. The commands demonstrate the structure and relationships intended for a shopping management system.

Uploaded by

uyenakaghe
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views2 pages

Script 20SQL 20xampp

The document outlines a series of MySQL commands to create a database named 'ShopMS' and several tables including 'author', 'Book', 'Warehouse_book', 'Warehouse', 'Publisher', 'ShoppingBasket_Book', 'Customer', and 'Shoppingbasket'. Each table is defined with specific fields and data types. The commands demonstrate the structure and relationships intended for a shopping management system.

Uploaded by

uyenakaghe
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd

C:\xampp\mysql\bin> mysql -uroot -p

show databases;
use information_schema; (database name)
show tables;
create database ShopMS;
use ShopMS;

create table author (


Name varchar(255),
Adress varchar(255),
URL varchar(255)
);

desc author;

create table Book(


ISBN varchar(255) not null,
PublisherName varchar(255) not null,
AuthorNnme varchar(255) not null,
AuthorAddress varchar(255) not null,
Year int default 2025,
Title varchar(255),
Price flaut default 50000,
Description text
);

create table Warehouse_book(


WarehouseCode integer(10) not null,
BookISBN varchar(255) not null,
Count integer(10)
);

create table Warehouse(


Code integer(10),
Phone varchar(255),
Address varchar(255)
);

Create table Publisher(


Name varchar(255),
Address varchar(255),
Phone varchar (255),
URL integer(10)
);

Create table ShoppingBasket_Book(


ShoppingBasketID integer(10) not null,
BookISBN varchar (255) not null,
Count integer(10)
);

Create table Customer(


Email varchar(255) not null,
Name varchar(255),
Phone varchar(255),
Address varchar(255)
);

Create table Shoppingbasket(


ID integer(10) not null,
CustomerEmail varchar(255)
);

You might also like