-read input row
-if column is of timestamp type - read input value using getValueAsSQLTyped method
- save microseconds value
- call custom method to convert Timezone (using Date and Calendar)
- add microseconds back
- write output value using setValueAsSQLTyped method.
After some tests it appears that when reading input value with getValueAsSQLTyped - microseconds are kept. BUT - when writing output value with setValueAsSQLTyped -microseconds are lost.
Here is debugging output to illustrate the issue:
APT_CombinedOperatorController,1: sqlTypeName---> Timestamp
in Tmst--> 2009-12-31 03:14:07.777215
date inside convertTmstTZ method--> 2009-12-31 03:14:07.777215
date after convertTZ --> Thu Dec 31 08:14:07 GMT 2009
Tmst after convertTZ --> 2009-12-31 08:14:07.0
Tmst after setNanos --> 2009-12-31 08:14:07.777215
outTmst---> 22009-12-31 08:14:07.777215
writing out Tmst value to TZA_---> 2009-12-31 08:14:07.777215-to column # 1
reading Tmst value back from output row---> 2009-12-31 08:14:07.0-from column # 1
Is it a bug in DS tr4j.jar? How to overcome it? Any thought would be appreciated!