Wednesday, March 29, 2017

cara membuat table di mysql

 
 
create table pembelian (
nonota varchar(10) primary key,
kdbrg varchar(10),kdsupplier varchar(10),
tanggalbeli date,
jumlahbeli int,
hargabeli int,
total int);



insert into pembelian VALUES ('HG001','HRG001','SUP006','03/01/2017','200','2000','400000')
insert into pembelian VALUES ('HG002','HRG004','SUP002','02/01/2017','150','3000','450000')
insert into pembelian VALUES ('HG003','HRG007','SUP001','02/01/2017','300','4000','1200000')
insert into pembelian VALUES ('HG004','HRG008','SUP003','04/01/2017','100','1500','150000')
insert into pembelian VALUES ('HG005','HRG009','SUP004','05/02/2017','225','1000','225000')
insert into pembelian VALUES ('HG006','HRG0010','SUP005','07/01/2017','500','4000','2000000')
insert into pembelian VALUES ('HG007','HRG0011','SUP007','08/02/2017','350','2000','700000')
insert into pembelian VALUES ('HG008','HRG005','SUP008','06/01/2017','400','1000','400000')
insert into pembelian VALUES ('HG009','HRG006','SUP008','01/01/2017','200','1000','200000')
insert into pembelian VALUES ('HG0010','HRG007','SUP009','06/01/2017','400','1000','400000')

 

0 comments:

Post a Comment