none
Formula Error while Executing as expression. RRS feed

  • Question

  • Hi,

    I am having a minor issue on the reports when I try to set up a formula as expression. My report return an error 

    An error occurred during local report processing I have used this formula 

    =Fields!ProductValue.Value/Fields!ExchangeRate.Value*Fields!BalanceQuantity.Value

    I want to get the result by running an easy formula but I am stuck

    ProductValue/ExchangeRate*Balancequantity=Balance

    and the other one is

    OrderQuantity-InvoicedQuantity=OustandingOrders

    no sure how I can put this as expression to get what I need?



    • Edited by Mo Yusuf Wednesday, April 1, 2015 2:11 PM
    Wednesday, April 1, 2015 2:00 PM

Answers

  • Hi Mo,

    According to your description, you want to create an expression to divide two values and other expression to make the difference between two fields, right?

    In Reporting Services, "/" is used to divide two numbers and returns a floating-point result. And “\” is used to divide two numbers and returns an integer result. “*” is used to multiply two numbers. In your scenario, the expression =Fields!ProductValue.Value/Fields!ExchangeRate.Value*Fields!BalanceQuantity.Value should be correct, since you mentioned the error occurs when running the report, please check if those three fields are numbers.

    Besides, "-" is used to return the difference between two numbers or indicates the negative value of a numeric term. You can specify the expression like below to make the difference:
    =Fields!OrderQuantity.Value - Fields!InvoicedQuantity.Value

    If issue persists, please check the error message when running the report. Also please share the data type of the sample data and report design for our analysis.

    If you have any question, please feel free to ask.

    Best regards,
    Qiuyun Yu


    Qiuyun Yu
    TechNet Community Support



    Thursday, April 2, 2015 2:51 AM
    Moderator
  • Hi ,

    You can try below;

    Make sure all the fields conatins integer value.

    =(Fields!ProductValue.Value/Fields!ExchangeRate.Value)*Fields!BalanceQuantity.Value
    Thanks

    Please Mark This As Answer or vote for Helpful Post if this helps you to solve your question/problem. http://techequation.com

    Thursday, April 2, 2015 4:50 AM

All replies

  • Can someone please help formula for division ? Is it something like this = productvalue/exchangerate*balancequantity=balance
    Wednesday, April 1, 2015 7:20 PM
  • Hi Mo,

    According to your description, you want to create an expression to divide two values and other expression to make the difference between two fields, right?

    In Reporting Services, "/" is used to divide two numbers and returns a floating-point result. And “\” is used to divide two numbers and returns an integer result. “*” is used to multiply two numbers. In your scenario, the expression =Fields!ProductValue.Value/Fields!ExchangeRate.Value*Fields!BalanceQuantity.Value should be correct, since you mentioned the error occurs when running the report, please check if those three fields are numbers.

    Besides, "-" is used to return the difference between two numbers or indicates the negative value of a numeric term. You can specify the expression like below to make the difference:
    =Fields!OrderQuantity.Value - Fields!InvoicedQuantity.Value

    If issue persists, please check the error message when running the report. Also please share the data type of the sample data and report design for our analysis.

    If you have any question, please feel free to ask.

    Best regards,
    Qiuyun Yu


    Qiuyun Yu
    TechNet Community Support



    Thursday, April 2, 2015 2:51 AM
    Moderator
  • Hi ,

    You can try below;

    Make sure all the fields conatins integer value.

    =(Fields!ProductValue.Value/Fields!ExchangeRate.Value)*Fields!BalanceQuantity.Value
    Thanks

    Please Mark This As Answer or vote for Helpful Post if this helps you to solve your question/problem. http://techequation.com

    Thursday, April 2, 2015 4:50 AM