Round with Aggregate
Hi,
sorry, but I read the manual - without success.
I created an invoice. In the groupfooter I have a field with an aggregate-function (SUM). It's the sum of the amounts. The next field calculates the processing fee. Adding these fields I often get differences. I think the reason is, that the fields are formatted with 2f but calculated with a lot of decimals more. So it happens, that 7,51+0,23=7,73. Similar Problems happen in Excel. There I fixed it by using round(..,2).
Inside SQL i can use round(Netto*(1+Art.StsProzent/100,2) to get the gross amount.
But what is the Syntax for using the round-function in textfields.
And more simple what is the syntax for the addition of two fields: the fields are named Memo24 and Memo28. I tried [Memo24]+[Memo28] and got a very large integer. [Memo24 + Memo28] made just an error.
How can I wrap the SUM with a round-function. [round(SUM(<Query0."ARTLEKPREISAUFSCHLAG">),2)] makes an error: ..Too many parameters.
Please give me hint where I can find the answers.
Thanks!
Tom
sorry, but I read the manual - without success.
I created an invoice. In the groupfooter I have a field with an aggregate-function (SUM). It's the sum of the amounts. The next field calculates the processing fee. Adding these fields I often get differences. I think the reason is, that the fields are formatted with 2f but calculated with a lot of decimals more. So it happens, that 7,51+0,23=7,73. Similar Problems happen in Excel. There I fixed it by using round(..,2).
Inside SQL i can use round(Netto*(1+Art.StsProzent/100,2) to get the gross amount.
But what is the Syntax for using the round-function in textfields.
And more simple what is the syntax for the addition of two fields: the fields are named Memo24 and Memo28. I tried [Memo24]+[Memo28] and got a very large integer. [Memo24 + Memo28] made just an error.
How can I wrap the SUM with a round-function. [round(SUM(<Query0."ARTLEKPREISAUFSCHLAG">),2)] makes an error: ..Too many parameters.
Please give me hint where I can find the answers.
Thanks!
Tom
Comments
The 'Round' does not take parameters in FR. How about trying something like this:
[round(SUM(<Query0."ARTLEKPREISAUFSCHLAG">)*100)/100]
I don't think that it is esasy to calculate directly from what is inside a memo. I think you should try to use whatever is the source for the memo in your calcluation:
Memo1: [Query0."NUMBER"]
Memo2: [sum(<Query0."NUMBER1">)]
Memo3 (Memo1 + Memo2): [<Query0."NUMBER"> + sum(<Query0."NUMBER1">)]
Petter
I misunderstood the Syntax of "Round" inside a report.
Thanks a lot!
Ciao
Tom