...
Code Block | ||
---|---|---|
| ||
def qapi = api.queryApi()
def p = qapi.tables().products()
return qapi.source(p, [p.sku(), p.label], p.sku().equal("MB-0001"))
.stream { it.collect { it } } |
...
Line 3: the reference to product master table is stored in qapi
p
variable.
Line 5: the source()
method says to query products table with a filter expression that defines which rows to return in the result
...