simulation shrink database
1. Create table & insert 5 million row for lab
CREATE TABLE TestTable (
ID INT IDENTITY(1,1) PRIMARY KEY,
Name NVARCHAR(50),
CreatedDate DATETIME
);
1. install ODBC postgresql * configure
http://teguhth.blogspot.com/2024/01/install-postgresql-odbc-driver-on-linux.html
A. using dblink
1. create table dblink example table barang
CREATE TABLE table_edb_barang(
KODE_BARANG char(6) not null ,
NAMA_BARANG varchar(25),
SATUAN_BARANG varchar(20),
STOK_BARANG decimal(4),
primary key (KODE_BARANG)) ENGINE = CONNECT TABLE_TYPE=ODBC TABNAME='barang' CONNECTION='DSN=edbdb';
A. ODBC Linux for MSSQL
1. prefer link
https://learn.microsoft.com/en-us/sql/connect/odbc/linux-mac/installing-the-microsoft-odbc-driver-for-sql-server?view=sql-server-ver16&tabs=redhat18-install%2Calpine17-install%2Cdebian8-install%2Credhat7-13-install%2Crhel7-offline
#Download appropriate package for the OS version
#Choose only ONE of the following, corresponding to your OS version