Hi,
We are reading in data from a Mainframe DB2 table defined as Decimal(3,0) and we are just passing this field through a transformer with the same metadata from the DB2 connector. The sequential file for this field ends up with a trailing decimal, is that expected?
ex: 123.
I know we can manipulate teh output if we declare it as a Varchar and do some basic string manipulation but wanted to check if this is the expected outcome for this scenario.
Thanks - - John
Question on Trailing Decimal in Sequential File
Moderators: chulett, rschirm, roy
-
- Premium Member
- Posts: 306
- Joined: Wed Jun 21, 2006 11:41 am
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Yes it is expected. When converting decimal to string DataStage adds a decimal placeholder and sufficient leading and trailing nonsignificant zeroes to make it clear what the precision and scale settings are.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
-
- Premium Member
- Posts: 306
- Joined: Wed Jun 21, 2006 11:41 am
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
You ARE converting to a string, because a text file does not have data types - it only has text (string).
Actually, it's the export operator that is performing the conversion.
Actually, it's the export operator that is performing the conversion.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.