A. Create Database & Table from Source & Destination
1. Create database source
tgh_source
2. create table source
create table barang(
KODE_BARANG char(6) not null ,
NAMA_BARANG varchar(25),
SATUAN_BARANG varchar(20),
STOK_BARANG decimal(4),
primary key (KODE_BARANG));
3. insert some table to Source Add
select * from barang;
insert into barang(KODE_BARANG,NAMA_BARANG,SATUAN_BARANG,STOK_BARANG) values('ELK-01','RICE COOKER','BUAH',20);
insert into barang(KODE_BARANG,NAMA_BARANG,SATUAN_BARANG,STOK_BARANG) values('ELK-02','LEMARI ES','UNIT',8);
-- next
insert into barang(KODE_BARANG,NAMA_BARANG,SATUAN_BARANG,STOK_BARANG) values('ELK-03','TELEVISI','UNIT',30);
insert into barang(KODE_BARANG,NAMA_BARANG,SATUAN_BARANG,STOK_BARANG) values('ELK-04','RADIO/TAPE','BUAH',35);
insert into barang(KODE_BARANG,NAMA_BARANG,SATUAN_BARANG,STOK_BARANG) values('ELK-05','KOMPUTER','UNIT',28);
insert into barang(KODE_BARANG,NAMA_BARANG,SATUAN_BARANG,STOK_BARANG) values('ELK-06','KIPAS ANGIN','BUAH',38);
select * from barang;
4. create database destination
tgh_destination
5. create table source
create table barang(
KODE_BARANG char(50) not null ,
NAMA_BARANG varchar(50),
SATUAN_BARANG varchar(50),
STOK_BARANG decimal(50),
primary key (KODE_BARANG));
6. Check table barang
select * from barang;
B. Create New SSIS , name LatTeguh01, souce & destination
C. Deploy Package SSIS & integration to SQL Server
D. Create Job SQL
E. Capture before run & test
use tgh_source;
select * from barang;
use tgh_destination
delete from barang
select * from barang;
F. Start Job Agent
G. Capture after run & test
No comments:
Post a Comment