/**Begin D:\pdm\PDM_UPGRADE\pdm_new\RIM_table.sql **/
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_RIM_INVOICE_FILE_AWS' AND KSQL_COL_NAME ='FATTACHMENT_NAME') 
 ALTER TABLE T_RIM_INVOICE_FILE_AWS ADD (FATTACHMENT_NAME NVARCHAR(50) DEFAULT ' ' NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_RIM_INVOICE_FILE_AWS' AND KSQL_COL_NAME ='FREMARK') 
 ALTER TABLE T_RIM_INVOICE_FILE_AWS ADD (FREMARK NVARCHAR(200) DEFAULT ' ' NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_RIM_INVOICE_FILE_AWS' AND KSQL_COL_NAME ='FORIGINAL_FILE_NAME') 
 ALTER TABLE T_RIM_INVOICE_FILE_AWS ADD (FORIGINAL_FILE_NAME NVARCHAR(100) DEFAULT ' ' NOT NULL );
IF NOT EXISTS (SELECT 1 FROM KSQL_USERCOLUMNS WHERE KSQL_COL_TABNAME = 'T_RIM_INVOICE_FILE_AWS' AND KSQL_COL_NAME ='FDOWN_TYPE') 
 ALTER TABLE T_RIM_INVOICE_FILE_AWS ADD (FDOWN_TYPE NVARCHAR(20) DEFAULT ' ' NOT NULL );

/**End D:\pdm\PDM_UPGRADE\pdm_new\RIM_table.sql **/
