IF NOT EXISTS (SELECT 1 FROM KSQL_USERTABLES WHERE KSQL_TABNAME = 'T_ER_XKBUGETVIEW')
CREATE TABLE T_ER_XKBUGETVIEW (
    FID BIGINT DEFAULT 0 NOT NULL
);
EXEC P_ALTERPK 'PK_T_ER_XKBUGETVIEW', 'T_ER_XKBUGETVIEW', 'FID', '1';