var query =datasources.db.example_data.person.createSelect();query.where.add(query.joins.person_to_parent.joins.person_to_parent.columns.name.eq('john'))foundset.loadRecords(query)
var query =datasources.db.example_data.orders.createSelect();query.groupBy.add(query.columns.orderid) // have to group by on pk when using having-conditions in (foundset) pk queries
.root.having.add(query.joins.orders_to_order_details.columns.quantity.count.eq(0))foundset.loadRecords(query)
add(function)
Add column name to group-by clause.
Same as query.groupBy().add(join.getColumn("value"))
var query =datasources.db.example_data.orders.createSelect();query.groupBy.add(query.columns.orderid) // have to group by on pk when using having-conditions in (foundset) pk queries
.root.having.add(query.joins.orders_to_order_details.columns.quantity.count.eq(0))foundset.loadRecords(query)
addPk()
Add the tables' primary pk columns in alphabetical order to the group by clause.
var query =datasources.db.example_data.orders.createSelect();query.groupBy.addPk() // have to group by on pk when using having-conditions in (foundset) pk queries.root.having.add(query.joins.orders_to_order_details.columns.quantity.count.eq(0))foundset.loadRecords(query)