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

multiply by negative

hiiii

value = ( v_rate / v_qty ) * -1

it dont work when i do *-1 any idea what to use

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

8 Answers

  • Posted on Nov 28, 2007 at 11:05 AM

    Hi,

    Do Try this..

    DATA:X type i value '2'.

    DATA:y type i Value '10'.

    DATA:Value type i.

    Value = ( Y / X ) * ( -1 ).

    Write:/ Value.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Nov 28, 2007 at 11:01 AM

    Do like this

    value = ( v_rate / v_qty ) * ( -1)

    it will work

    cheers

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Nov 28, 2007 at 11:01 AM

    HI ,

    vaule = (v_rate / v_qty ) * (-1)

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Nov 28, 2007 at 11:02 AM

    declare a variable with type p,it can store a negative value and use it.

    Regards,

    Amit

    Reward all helpful replies.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Nov 28, 2007 at 11:03 AM

    value = ( v_rate / v_qty ) * ( -1 ).

    observe the space before and after -1

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Nov 28, 2007 at 11:04 AM

    Hi,

    Do like this.

    value = ( v_rate / v_qty ) * ( -1 )

    Regards,

    Prashant

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Nov 28, 2007 at 11:21 AM

    Hi,

    See Below Code..

    DATA:X type P Decimals 2 value '12.12'.

    DATA:y type P Decimals 2 Value '100.12'.

    DATA:Value type p DECIMALS 3.

    Value = ( Y / X ) * ( -1 ).

    Write:/ VALUE.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Nov 30, 2007 at 06:55 AM

    solve

    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.