I must be missing something obvious here, how has the column "utm_northing" landed in the third position in this query output?
Which build are you running?
Could it be that you repositioned 'utm_northing' using the Layers pane? Re-running the query should reset the order, at least in the last published cutting edge build.
If it is not that, it would be helpful if you posted an MXB with the query and the table (no records needed, but don't re-create the table, keep the original, because who knows, maybe this has to do with the order of fields or indexes in the schema).
I've attached a MAP file containing a single query component which creates the (empty) table, as well as another query component.
Running that additional query component returns 0 rows, but also mis-orders the columns. I can't quite tell what I'm doing wrong, or if the two calculated columns are confusing the query.
I'm running 169.5.
Thanks for having a look.
EDIT: I also just noticed that the table (but not the schema) displays the columns in some arbitrary order, disagreeing with the order in which the columns appear in the CREATE statement.
I don't think your doing anything wrong. I came across this before, not knowing how I got there.
In mfd_meta you could try to edit the nr in 'Item.<nr>' and the Z-order.
Thanks for example data!
We found it. This is an oversight on our part, we will fix it. The reordering occurs when viewing tables with more than 10 fields, both regular tables and tables returned by queries. The effect is merely visual and you can fix the ordering in the Layers pane, but you shouldn't have to be doing that.