MetaSQL is an extension of the SQL database query language. You can find documentation for it on the xTuple web site at http://www.xtuple.org/RptAdvancedTopics.
The MetaSQL editor embedded in xTuple ERP allows creating, editing, and running ad-hoc database queries within the xTuple ERP application. xTuple Connect extends this capability to allow sending MetaSQL statements to the xTuple Connect Batch Manager to be run. Once submitted, these jobs can be scheduled to recur (see Section 3, “Scheduling Recurring Jobs” in Chapter 3, Connect Inside Your Company).
Individual MetaSQL statements can be grouped together into Query Sets. There is an introduction to Query Sets in Section 3, “Sending CSV Files”. They are discussed in more detail in Section 7.3.2, “Query Sets in xTuple Connect”. Query Sets can also be submitted to the xTuple Connect Batch Manager and scheduled to recur.
Both Query Sets and individual MetaSQL statements get submitted to the xTuple Connect Batch Manager using the EDI infrastructure. There are two System EDI Profiles for this purpose, one for individual MetaSQL statements and another for Query Sets.