-- Licensed Materials - Property of IBM
--
-- BI and PM: CM
--
-- (C) Copyright IBM Corp. 2010
--
-- US Government Users Restricted Rights - Use, duplication or disclosure
-- restricted by GSA ADP Schedule Contract with IBM Corp.

CREATE TABLE CMARCHIVEQUEUE (
	OBJID 	 	lvarchar(255) default null,
	ITEMID	 	lvarchar(255) not null,
	QUEUEID		lvarchar(255) not null,
	WORKFLOW 	lvarchar(255) not null,
	CONSUMERNAME	lvarchar(255) default null,
	STATE		integer,
	INSERTIONTIME 	datetime year to fraction not null,
	PRIMARY KEY (ITEMID) CONSTRAINT PK_CMARCHIVEQUEUE  
)lock mode row;

CREATE TABLE CMDELETEQUEUE (
	OBJID 	 	lvarchar(255) default null,
	ITEMID	 	lvarchar(255) not null,
	QUEUEID		lvarchar(255) not null,
	WORKFLOW 	lvarchar(255) not null,
	CONSUMERNAME	lvarchar(255) default null,
	STATE		integer,
	INSERTIONTIME 	datetime year to fraction not null,
	PRIMARY KEY (ITEMID) CONSTRAINT PK_CMDELETEQUEUE  
)lock mode row;


CREATE TABLE CMQUEUELOCK (
	QUEUEID		lvarchar(255) not null,
	PRIMARY KEY (QUEUEID) CONSTRAINT PK_CMQUEUELOCK 
)lock mode row;
