Hi,
I have the following Grails domain objects
class ProductType {
String name
static hasMany = [attributes: Attribute]
}
class Attribute {
Boolean mandatory = false
Integer seq
static belongsTo = [productType: ProductType]
}
I would like to get all ProductTypes and their mandatory Attributes. Furthermore, I'd like the selected Attributes to be eagerly loaded and sorted by the seq property. I've tried all kinds of HQL and Criteria queries, but can't seem to figure it out.