IBM Support

Converting data type from VARCHAR to VARGRAPHIC in maximo db2 database.

Technical Blog Post


Abstract

Converting data type from VARCHAR to VARGRAPHIC in maximo db2 database.

Body

Please use the fallowing sql that would create ALTER statements then execute them

 

 

SELECT 'ALTER TABLE '||TBNAME||' ALTER COLUMN '||NAME||'SET DATA TYPE '||'VARGRAPHIC'||'('||LENGTH||')'||';'

FROM SYSIBM.SYSCOLUMNS where TBCREATOR ='MAXIMO' AND COLTYPE='VARCHAR'

[{"Business Unit":{"code":"BU005","label":"IoT"}, "Product":{"code":"SSLKT6","label":"Maximo Asset Management"},"Component":"","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"","Edition":""}]

UID

ibm11132101