Active Objects, how to sum a numeric column

Im guessing this can't be done right now, someone correct me if Im wrong, this older post shows count() operators, exposed by AO, but there is no sum() operator.

https://answers.atlassian.com/questions/24246/active-objects-is-it-possible-to-get-count-using-group-by-in-ao

Without reading all data, how to SUM a numeric column in a table?

2 answers

1 accepted

Accepted Answer
0 votes

You're right Andy, no way to do SUM columns at the moment. Active Objects works on Objects, and doesn't allow (at the moment) working on individual columns to compute values.

Feel free to raise a feature request though, http://studio.atlassian.com/browse/AO

Hi,

At the movement i can-not give you any Active Objects Example

but using hibernate it is possible eg. Long sum = Projections.sum("Name of column");

Active object is similar you can try this may be it will work.

I am not familar to hibernate, what's Projections?

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Tuesday in Featured Groups

Tuesday tips & tricks: What is the Atlassian Community?

It's officially Tuesday, which means it's officially time for another tip to help you better navigate this space we call the Atlassian Community. 😄 I got a great question from community member, Sa...

56 views 2 5
View post

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you