Skip to Content
author's profile photo Former Member
Former Member

Type conversion

Hi,

I need to convert a variable dec(11) in a char variable.

write dec_variable to char_variable

and

move dec_variable to char_variable

doesn´t work.

How can I do it??

Yhanks.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

4 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Nov 23, 2007 at 10:37 AM

    try this...

    data: pd(11) type p decimals 2 value '20.00',

    ch(15) type c.

    ch = pd.

    write: pd, ch.

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Nov 23, 2007 at 10:35 AM

    Write should work. What are the data definitions of dec_variable and char_variable. What results do you get when you try?

    matt

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Nov 23, 2007 at 10:36 AM

    hi,

    try to move it to string variable

    regards,

    pavan

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Nov 23, 2007 at 10:41 AM

    Hi

    report zrich_0001 .

    data:

    wa_char_results-mean_value type labst value '123456123.789',

    wa_zbdprt_alv-mean_value type char16.

    write wa_char_results-mean_value to wa_zbdprt_alv-mean_value .

    write:/ wa_zbdprt_alv-mean_value.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.