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

converting a dec field

sanjeev_das4
Explorer
0 Likes
715

I am storing output to a text file in application server . The internal table has a field of DEC type and hence it is throwing an error that it cannot be converted to a text file . It has to be of cahrater type data object . Any suggestion will be highly appreciated

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
678

Hi Sanjeev,

Before populating the internal table data to the file, pass on the DEC value to a string temporary variable and copy the value from this string temp variable to the actual file variable. And populate.

@ Moderators: This could be a basic question, but it seems to be that Sanjeev got confused with the logic and posted this thread. I've just cleared the doubt.

Regards,

-Syed.

Hi Sanjeev,

Before populating the internal table data to the file, pass on the DEC value to a string temporary variable and copy the value from this string temp variable to the actual file variable. And populate.

@ Moderators: This could be a basic question, but it seems to be that Sanjeev got confused with the logic and posted this thread. I've just cleared the doubt.

Regards,

-Syed.

4 REPLIES 4
Read only

Former Member
0 Likes
679

Hi Sanjeev,

Before populating the internal table data to the file, pass on the DEC value to a string temporary variable and copy the value from this string temp variable to the actual file variable. And populate.

@ Moderators: This could be a basic question, but it seems to be that Sanjeev got confused with the logic and posted this thread. I've just cleared the doubt.

Regards,

-Syed.

Read only

Former Member
0 Likes
678

dear Sanjeev,

Try to use filed type string to trafer decimal data .

Regards,

Vijay

Read only

Former Member
0 Likes
678

Hi ,

pass that value to a string & then append it in final int table

Read only

Former Member
0 Likes
678

Hi

Before sending the file to application server, take another internal table with same structure as existing with a chnage instead of decimal field take char field with some length. And fill that new table with loop on existing table, and send the file with data from new table to application server.

thanks