Have a look here: https://github.com/apache/cloudstack/blob/master/engine/schema/src/com/cloud/storage/dao/VolumeDaoImpl.java#L347
Or you can search other example in the code base with this string "Func.SUM": thttps:// github.com/apache/cloudstack/blob/master/engine/schema/src/com/cloud/storage/dao/VolumeDaoImpl.java#L347 On Wed, Jan 10, 2018 at 9:42 AM, Ivan Kudryavtsev <kudryavtsev...@bw-sw.com> wrote: > Hello, colleagues, please could anyone guide me how to implement > aggregation SUM over two fields multiplication? Many thanks in advance. > > I'm trying to achieve: > SELECT SUM(A * B) FROM T with DAO > > > > -- > With best regards, Ivan Kudryavtsev > Bitworks Software, Ltd. > Cell: +7-923-414-1515 > WWW: http://bitworks.software/ <http://bw-sw.com/> >