MODE-1680 The xpath query is not well-formed
MODE-1680: 
Remove unused commented lines
Add more checks at the parsing stage
MODE-1680: Extend query processor to allow use aliased joinings
MODE-1680 Improved support for ORDER BY columns not in SELECT

Improved the behavior of JCR-SQL2 and JCR-QOM queries that use
columns not in the SELECT clause. Such columns are necessary
within the query processing to evaluate the ordering, but are not
to be exposed in the query results. One particular case needed
by the recent XPath improvements (to handle order-by clauses that
involve a property on the child node) resulted in the ORDER BY
column coming from a selector that was not even included in the
SELECT.

A test case recently added in other MODE-1680 commits was modified
to verify the XPath and JCR-SQL2 behavior is as expected. Also added
another query test that uses only JCR-SQL2.