If you are unable to create a new account, please email support@bspsoftware.com

 

News:

MetaManager - Administrative Tools for IBM Cognos
Pricing starting at $2,100
Download Now    Learn More

Main Menu

Packed Decimal in text field

Started by terry_stjean, 21 Apr 2013 06:36:52 AM

Previous topic - Next topic

terry_stjean

I have a file which has a Packed Decimal Date (YYYYMMDD) in a char field.
When I import this data in using Data Manager, how do I convert the Packd Decimal to an Integer value so I can get the date value.

MFGF

Hi. Just use a toInteger() function in your derivation if you want to convert it to an integer value.

Cheers!

MF.

Sent from my iPad using Tapatalk HD
Meep!

terry_stjean

Hi,
It's returning a 0 value.
Could the issue be due to the packed decimal being in a char field?

siyad

my 2 cents...
I am just thinking if you have configured your definition file to take the type of this field as integer and it woould flow through as an integer. Also check the data
type of this column at the data stream too

terry_stjean

It's not from a flat text file.
It's from a table on an iSeries server

siyad

ok...it looks a bit strange and cant think any more, other than checking for the spaces before or after the yyyymmdd

MFGF

What results do you get if you use a toChar() function on the item before you use toInteger()? Does this parse and work ok?

MF.
Meep!

terry_stjean

When I use ToChar(), I get 0 instead of the actual number.

MFGF

Bizarre! I have not seen that before. If you create a new datastream item with a Type of Integer, then map your date field to this, do you see the expected value in the datastream item, or still zero?

MF.
Meep!