code: public QueryResult printQuery( Session session,
                                     String jcrSql2,
                                     long expectedNumberOfResults,
                                     Map<String, String> variables ) throws RepositoryException {
          return printQuery(session, jcrSql2, Query.JCR_SQL2, expectedNumberOfResults, variables);
      }
docs: Execute the supplied JCR-SQL2 query and, if printing is enabled, print out the results.
  
  @param session the session
  @param jcrSql2 the JCR-SQL2 query
  @param expectedNumberOfResults the expected number of rows in the results, or -1 if this is not to be checked
  @param variables the array of variable maps for the query; all maps will be combined into a single map
  @return the results
  @throws RepositoryException