Skip to Content
avatar image
Former Member

Request M_TIME_DIMENSION table definition

Hi,

I have lost M_TIME_DIMENSION table for some reason. Can someone provide me the definition of this table from _SYS_BI schema.

Thank you.

Regards,

Benny

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Best Answer
    May 09, 2017 at 08:29 PM

    Following you can find the create statement for the table valid on a HANA 1.0 SPS12 system and a HANA 2.0 SPS01 system.

    CREATE COLUMN TABLE "_SYS_BI"."M_TIME_DIMENSION"(
    	"DATETIMESTAMP" LONGDATE CS_LONGDATE NOT NULL,
    	"DATE_SQL" DATE CS_DAYDATE,
    	"DATETIME_SAP" VARCHAR(14),
    	"DATE_SAP" VARCHAR(8),
    	"YEAR" VARCHAR(4),
    	"QUARTER" VARCHAR(2),
    	"MONTH" VARCHAR(2),
    	"WEEK" VARCHAR(2),
    	"WEEK_YEAR" VARCHAR(4),
    	"DAY_OF_WEEK" VARCHAR(2),
    	"DAY" VARCHAR(2),
    	"HOUR" VARCHAR(2),
    	"MINUTE" VARCHAR(2),
    	"SECOND" VARCHAR(2),
    	"CALQUARTER" VARCHAR(5),
    	"CALMONTH" VARCHAR(6),
    	"CALWEEK" VARCHAR(6),
    	"YEAR_INT" INTEGER CS_INT,
    	"QUARTER_INT" TINYINT CS_INT,
    	"MONTH_INT" TINYINT CS_INT,
    	"WEEK_INT" TINYINT CS_INT,
    	"WEEK_YEAR_INT" INTEGER CS_INT,
    	"DAY_OF_WEEK_INT" TINYINT CS_INT,
    	"DAY_INT" TINYINT CS_INT,
    	"HOUR_INT" TINYINT CS_INT,
    	"MINUTE_INT" TINYINT CS_INT,
    	"SECOND_INT" TINYINT CS_INT,
    	"MONTH_LAST_DAY" TINYINT CS_INT,
    	"TZNTSTMPS" DECIMAL(15) CS_FIXED,
    	"TZNTSTMPL" DECIMAL(21, 7) CS_FIXED,
    	PRIMARY KEY (
    		"DATETIMESTAMP"
    	)
    ) UNLOAD PRIORITY 0 AUTO MERGE;
    
    Add comment
    10|10000 characters needed characters exceeded