Not getting expected results through time(6)

Database
Enthusiast

Not getting expected results through time(6)

hi Experts,

 Not getting the expected results by using time(6) datatype for one of a column.

We expect the output to be as HH:MM:SS.S(6) but the fraction part  is not coming through this

I tried in both bteq and sql assistant but the fractional part is not getting displayed.

I checked the documentation that the format of time is defined at the system level and tdlocaldef file

needs to be updated for that..

Just to get a quick work around, we found INTERVAl HOUR(4) to sec(6) ,this seems to be 

giving the perfect results.

Please correct me if i am missing some thing above.

cheers!

Nishant

Tags (1)
2 REPLIES
Senior Apprentice

Re: Not getting expected results through time(6)

Hi Nishant,

do a SELECT FORMAT(table.timecol) or a SHOW/HELP TABLE to check if it's actually a TIME and no INTEGER (based on some settings ODBC might replace TIME with INT)

Dieter

Enthusiast

Re: Not getting expected results through time(6)

Thanks Dieter !