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

-- Copyright (C) 2008 Cognos ULC, an IBM Company. All rights reserved.
-- Cognos (R) is a trademark of Cognos ULC, (formerly Cognos Incorporated).


alter table CMOBJPROPS31 add PACSAUDITLVL tinyint null

alter table CMOBJPROPS31 add PRSAUDITLVL tinyint null

alter table CMOBJPROPS31 add PTSAUDITLVL tinyint null

CREATE TABLE CMOBJPROPS40 (
	CMID			int NOT NULL ,
	APPGUID			varchar(50) NULL ,
	APPID			nvarchar (256) NULL ,
	APPSTATE		tinyint NULL ,
	APPURL			nvarchar (4000) NULL ,
	CONSTRAINT PK_CMOBJPROPS40 PRIMARY KEY (CMID)
)

CREATE TABLE CMOBJPROPS41 (
	CMID			int NOT NULL ,
	DEPTH			int null,
	ITEMID			nvarchar (256) NULL ,
	PARENTID		nvarchar (256) NULL ,
	CONSTRAINT PK_CMOBJPROPS41 PRIMARY KEY (CMID)
)

CREATE TABLE CMOBJPROPS42 (
	CMID			int NOT NULL ,
	SPEC			ntext NULL ,
	CONSTRAINT PK_CMOBJPROPS42 PRIMARY KEY (CMID)
)

!RunCMScript CMUpgradeScript_configuration_update_4.xml

!RunCMScript CMUpgradeScript_cognos_roles2_add.xml

!RunCMScript CMUpgradeScript_cognos_roles2_update.xml

!RunCMScript CMUpgradeScript_capabilities_22_add.xml

!RunCMScript CMUpgradeScript_capabilities_22_update.xml