CREATE DATABASE COMPANY;
CREATE DBSPACE MYDBSP_1 ALLOCATE FILE /jdbc/COMPANY.dbs ATTRIBUTE SPACE (20M);
CREATE SCHEMA GENERAL;
CREATE TABLE GENERAL.EMPLOYEE (ID INT NOT NULL,
NAME CHARACTER(20),
PRIMARY KEY(ID));
CREATE TABLE GENERAL.BLOBTBL(
A_INT INT NOT NULL,
A_BLOB BLOB(100K),
PRIMARY KEY(A_INT)) ON MYDBSP_1;
CREATE DSO DSO01
FROM GENERAL.EMPLOYEE
TYPE RANDOM (PAGESIZE1(4),PAGESIZE2(4));
CREATE DSI DSI01
DSO DSO01
ALLOCATE PRIME ON MYDBSP_1 SIZE 200K,OVERFLOW ON MYDBSP_1 SIZE 80K;
CREATE INDEX GENERAL.EMPLOYEE.TB1IDX KEY(ID) ON MYDBSP_1;
CREATE INDEX GENERAL.BLOBTBL.TB1IDX KEY(A_INT) ON MYDBSP_1;
GRANT ALL PRIVILEGES ON GENERAL.EMPLOYEE TO PUBLIC;
GRANT ALL PRIVILEGES ON GENERAL.BLOBTBL TO PUBLIC;
GRANT ALL PRIVILEGES ON SCHEMA GENERAL TO PUBLIC;
GRANT ALL PRIVILEGES ON DBSPACE MYDBSP_1 TO PUBLIC; |