Hi,
I am trying to calculate values based on my attributes.
I accessed this link to help me https://success.outsystems.com/Documentation/10/Developing_an_Application/Use_Data/Query_Data/Aggregate_a_Column_into_a_Single_Value
https://www.outsystems.com/training/lesson/1975/demo-how-to-create-aggregation-functions-in-aggregates
But the menus presented do not correspond
What's going on?
i pretend to:
and
can I do the calculations directly on the screen? or do I have to do it in the database?
And how do I do the calculations?
Thanks
Can you check the datatype you used for these IVA attributes. It looks like they might be defined as alphanumeric, which you can´ t sum.
Hi SpiritFox,
As the Dorine said, please check data type for your required attributes, you cannot sum or average the attribute which includes text strings.
The SQL Server SUM() function is an aggregate function that calculates the sum of all or distinct numeric values of a column into a table. However, it looks like the values you are trying to sum is alpha numeric where it will not work.
SUM()
Thanks & Regards,
Sachin
Hi all,
The datatyoe is currency. i double check!
Can you share the oml ?
Do you want show your sum values in the table only or you want to just calculate and show it somewhere else?
I want it to appear on the screens
I want it to be possible for users to see
I'm able to show it on the screen like this, is it ok for you?
Here I have attached an OML to how to get values from the database for sum of rows and columns of the aggregate. You can show them on the screen as per your convenience.
Hope it works, Thanks and Happy Coding :)
Don't get me wrong, but I want to learn how to do it, so that in the future I can develop by myself. Thank you. I'll see how you did it.
How did you insert these attributes?
I've seen a video about it but I can't find it ...
Hi SpritFox,
These are the calculated attributes, You can find its steps from the below documentation.
https://success.outsystems.com/Documentation/11/Developing_an_Application/Use_Data/Query_Data/Create_a_Calculated_Attribute_in_an_Aggregate
Hope this helps!
Please check the attached example on how to get row and coulmn sum values.
Thank you Ravi
I don't understand what this means:
"€", 2, ".", ",")
In the expression:
FormatCurrency (GetTrocas2.List.Current.IVA_6Sum, "€", 2, ".", ",")
where can i find information about this?
Google "outsystems formatcurrency", and https://success.outsystems.com/Documentation/11/Reference/OutSystems_Language/Logic/Built-in_Functions/Format#FormatCurrency is first result.
You can find the details in service studio only when you use the function in an expression or assignment operator.
Please refer the screen shot below -
Let me know if this helps.
Unnati.