I have a queryable state in which I have a sender and amount fields. Is it possible to write a custom HQL or JPQL queries to get the total sum grouped by each sender. example
select sender,sum(amount) from stateTable group by sender
If possible please let me know how
I used the JDBC session present in the serviceHub to add the custom JDBC query. Please find below the reference for the same
https://docs.corda.net/api-persistence.html#jdbc-session-ref