001    /**
002     * Copyright (c) 2000-2013 Liferay, Inc. All rights reserved.
003     *
004     * The contents of this file are subject to the terms of the Liferay Enterprise
005     * Subscription License ("License"). You may not use this file except in
006     * compliance with the License. You can obtain a copy of the License by
007     * contacting Liferay, Inc. See the License for the specific language governing
008     * permissions and limitations under the License, including but not limited to
009     * distribution rights of the Software.
010     *
011     *
012     *
013     */
014    
015    package com.liferay.portal.upgrade.v6_2_0.util;
016    
017    import java.sql.Types;
018    
019    /**
020     * @author        Brian Wing Shun Chan
021     * @generated
022     */
023    public class LayoutRevisionTable {
024    
025            public static final String TABLE_NAME = "LayoutRevision";
026    
027            public static final Object[][] TABLE_COLUMNS = {
028                    {"layoutRevisionId", Types.BIGINT},
029                    {"groupId", Types.BIGINT},
030                    {"companyId", Types.BIGINT},
031                    {"userId", Types.BIGINT},
032                    {"userName", Types.VARCHAR},
033                    {"createDate", Types.TIMESTAMP},
034                    {"modifiedDate", Types.TIMESTAMP},
035                    {"layoutSetBranchId", Types.BIGINT},
036                    {"layoutBranchId", Types.BIGINT},
037                    {"parentLayoutRevisionId", Types.BIGINT},
038                    {"head", Types.BOOLEAN},
039                    {"major", Types.BOOLEAN},
040                    {"plid", Types.BIGINT},
041                    {"privateLayout", Types.BOOLEAN},
042                    {"name", Types.VARCHAR},
043                    {"title", Types.VARCHAR},
044                    {"description", Types.VARCHAR},
045                    {"keywords", Types.VARCHAR},
046                    {"robots", Types.VARCHAR},
047                    {"typeSettings", Types.CLOB},
048                    {"iconImage", Types.BOOLEAN},
049                    {"iconImageId", Types.BIGINT},
050                    {"themeId", Types.VARCHAR},
051                    {"colorSchemeId", Types.VARCHAR},
052                    {"wapThemeId", Types.VARCHAR},
053                    {"wapColorSchemeId", Types.VARCHAR},
054                    {"css", Types.CLOB},
055                    {"status", Types.INTEGER},
056                    {"statusByUserId", Types.BIGINT},
057                    {"statusByUserName", Types.VARCHAR},
058                    {"statusDate", Types.TIMESTAMP}
059            };
060    
061            public static final String TABLE_SQL_CREATE = "create table LayoutRevision (layoutRevisionId LONG not null primary key,groupId LONG,companyId LONG,userId LONG,userName VARCHAR(75) null,createDate DATE null,modifiedDate DATE null,layoutSetBranchId LONG,layoutBranchId LONG,parentLayoutRevisionId LONG,head BOOLEAN,major BOOLEAN,plid LONG,privateLayout BOOLEAN,name STRING null,title STRING null,description STRING null,keywords STRING null,robots STRING null,typeSettings TEXT null,iconImage BOOLEAN,iconImageId LONG,themeId VARCHAR(75) null,colorSchemeId VARCHAR(75) null,wapThemeId VARCHAR(75) null,wapColorSchemeId VARCHAR(75) null,css TEXT null,status INTEGER,statusByUserId LONG,statusByUserName VARCHAR(75) null,statusDate DATE null)";
062    
063            public static final String TABLE_SQL_DROP = "drop table LayoutRevision";
064    
065            public static final String[] TABLE_SQL_ADD_INDEXES = {
066                    "create index IX_43E8286A on LayoutRevision (head, plid)",
067                    "create index IX_314B621A on LayoutRevision (layoutSetBranchId)",
068                    "create index IX_A9AC086E on LayoutRevision (layoutSetBranchId, head)",
069                    "create index IX_E10AC39 on LayoutRevision (layoutSetBranchId, head, plid)",
070                    "create index IX_13984800 on LayoutRevision (layoutSetBranchId, layoutBranchId, plid)",
071                    "create index IX_4A84AF43 on LayoutRevision (layoutSetBranchId, parentLayoutRevisionId, plid)",
072                    "create index IX_B7B914E5 on LayoutRevision (layoutSetBranchId, plid)",
073                    "create index IX_70DA9ECB on LayoutRevision (layoutSetBranchId, plid, status)",
074                    "create index IX_7FFAE700 on LayoutRevision (layoutSetBranchId, status)",
075                    "create index IX_9329C9D6 on LayoutRevision (plid)",
076                    "create index IX_8EC3D2BC on LayoutRevision (plid, status)"
077            };
078    
079    }