How to reformat the Columnlength field in dbc.columnsv

Database
Enthusiast

How to reformat the Columnlength field in dbc.columnsv

Hi,

I can read the dbc.columnlenght fields as

e.g:- 1,000 

         2,000

But I am going to use this columnlength values in other SQL,..I am trying to seee output for

SEL  TRIM(Columnlength)

FROM DBC.COLUMNSV

WHERE DATABASENAME ='bjkdhdj'

AND TABLENAME ='ddjhkf';

Output I am getting as 1,000

but I want the output as 1000.

I thought its simple ,but while trying to find the solutions my mind is going blank completely.

Please guide me..

Rad

1 REPLY
Enthusiast

Re: How to reformat the Columnlength field in dbc.columnsv

Hey Guys,

I Found the answer, this may help for the people kind of me...

SEL CAST(TRIM(Columnlength) AS INTEGER)

FROM DBC.COLUMNSV

WHERE DATABASENAME ='bjkdhdj'

AND TABLENAME ='ddjhkf';

Output I am getting as 1000.

This is not worked for me in my SQL assistant ,bcoz of the option {Display 1000 seperators in neumaric columns} checked in the my SQL assistant Options