Appendix A

less than 1 minute read

Additional setup in DB2 databases

SICS stores eMessages in the database by using a table containing a CLOB column. In DB2 databases it is therefore needed to create a LOB tablespace and a support table.

This is a 2-step process that must be performed by the database administrator

Step 1 - create the LOB tablespace (if missing)

This is achieved by executing this script:

CREATE LOB TABLESPACE <TABLESPACE_NAME>
	IN <TS_DATABASE>
LOG NO
	COMPRESS YES;
COMMIT;

The same tablespace can be used for storing eMessages for different SICS databases.

Step 2 - create the support table

This is achieved by executing this script:

CREATE AUXILIARY TABLE <A_NAME>
	IN <TS_DATABASE>.<TABLESPACE_NAME>
STORES <SICS_DATABASE>.XML_DOCUMENT
	COLUMN XML_DATA;
CREATE UNIQUE INDEX X_XML_DATA
	ON <A_NAME>;
COMMIT;