Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Decimal Data type

Former Member
0 Likes
774

Hi All,

I have a problem while printing field value of DECimal data type . iam fectching a field named KURSF from BKPF into a internal table and finally this internal table values are downloaded to application server. the problem is when viewing the file downloaded in application server i can see hashes in the field value of KURSF instead of actual values

Thanks in Advance,

Neha

5 REPLIES 5
Read only

Former Member
0 Likes
692

i guess, the values are truncated. can you check the field length defined in that internal table?

field to which you are populating the database values.

regards

srikanth

Message was edited by: Srikanth Kidambi

Read only

andreas_mann3
Active Contributor
0 Likes
692

hi,

move that field (kursf) before download to a char-field,

because it's a packed value - that you cannot use for other applications!

A.

Message was edited by: Andreas Mann

Read only

Former Member
0 Likes
692

The problem is not with the decimal points but when you transfer command with an itab with pack fields, you would see that sort of issue.

Best is to use UNPACK command basically to convert the value to char/numeric and than transfer it.

So the soln is define the internal table with character field (make sure that you have the lenght as twice the len of pack field). UNPACK the pack field to char/num field and than transfer.

Regards

Anurag

Read only

Former Member
0 Likes
692

Hi,

When downloading CURRENCY or DECIMAL fields, you should MOVE the data into a CHARACTER Variable and then TRANSFER it to application server.

data : l_kursf type bkpf-kursf.

MOVE wa_tab-KURSF to l_kursf.

concatenate wa_tab-field1

wa_tab-field2

l_kursf

into l_string separated by `,`.

Transfer l_string to l_file.

close dataset.

Best regards,

Prashant

Read only

Former Member
0 Likes
692

Hi,

that problem is common, since it will fail to transfer the currency fields. so you need to convert that to Char and transfer it to application server. then you can see the data .

The problem is with the currency fields, try to convert it to char and check./

Regards

vijay