I would like to export the results of the following flexible query:
select {o.extendedorderid},{o.code}, {s.code}, {creationtime} from {order as o join orderstatus as s on {o.status}={s.pk}} where {s.code} = 'SUBMITTED'
I have been researching but still coming up short.