Examples of parseQuery()


Examples of com.caucho.db.Database.parseQuery()

    Database db = getDatabase();
   
    if (db == null)
      throw new SQLException(L.l("statement is closed"));

    Query query = db.parseQuery(sql);
   
    java.sql.ResultSet rs = executeQuery(query, getQueryContext());

    return rs;
  }
View Full Code Here

Examples of com.flaptor.indextank.query.IndexEngineParser.parseQuery()

        return new FunctionRangeFilter(scorer, dynamicDataManager, filters);
    }

    private Query generateQuery(String str, int start, int len, QueryVariables vars, Multimap<String, String> facetsFilter, MatchFilter rangeFilters) throws ParseException {
        IndexEngineParser parser = engine.getParser();
        return new Query(parser.parseQuery(str), str, vars, facetsFilter, rangeFilters);
    }

    private Multimap<String, String> convertToMultimap(List<CategoryFilter> facetsFilter) {
        Multimap<String, String> result = HashMultimap.create();
        for (CategoryFilter facetFilter : facetsFilter) {
View Full Code Here

Examples of com.google.visualization.datasource.query.parser.QueryBuilder.parseQuery()

   * @throws InvalidQueryException If the query is invalid.
   */
  public static Query parseQuery(String queryString, ULocale userLocale)
      throws InvalidQueryException {
    QueryBuilder queryBuilder = QueryBuilder.getInstance();
    Query query = queryBuilder.parseQuery(queryString, userLocale);

    return query;
  }

  /**
 
View Full Code Here

Examples of com.salesforce.phoenix.parse.SQLParser.parseQuery()

public class LimitClauseTest extends BaseConnectionlessQueryTest {
   
    private static Integer compileStatement(String query, List<Object> binds, Scan scan) throws SQLException {
        SQLParser parser = new SQLParser(query);
        SelectStatement statement = parser.parseQuery();
        PhoenixConnection pconn = DriverManager.getConnection(getUrl(), TEST_PROPERTIES).unwrap(PhoenixConnection.class);
        ColumnResolver resolver = FromCompiler.getResolver(statement, pconn);
        statement = StatementNormalizer.normalize(statement, resolver);
        StatementContext context = new StatementContext(new PhoenixStatement(pconn), resolver, binds, scan);
View Full Code Here

Examples of mondrian.olap.Connection.parseQuery()

            final Connection connection =
                getConnection(dsCatalog, role, roleName);

            final Query query;
            try {
                query = connection.parseQuery(statement);
                query.setResultStyle(ResultStyle.LIST);
            } catch (XmlaException ex) {
                throw ex;
            } catch (Exception ex) {
                throw new XmlaException(
View Full Code Here

Examples of mondrian.olap.Connection.parseQuery()

    Connection mondrianConnection = smdt.getConnection();
    // retrieves CacheControl object
    CacheControl cacheControl = mondrianConnection.getCacheControl(null);
    // retrieves the MDX query
    MdxQuery mdxQuery = (MdxQuery) olapModel.getExtension("mdxQuery");
    Query mondrianQuery = mondrianConnection.parseQuery(mdxQuery.getMdxQuery());
    // finds the cube in the MDX query
      Cube cube = mondrianQuery.getCube();
      // flush cache on all measures for that cube
      CacheControl.CellRegion measuresRegion = cacheControl.createMeasuresRegion(cube);
      cacheControl.flush(measuresRegion);
View Full Code Here

Examples of mondrian.olap.Connection.parseQuery()

    Connection monConnection = smdt.getConnection();
    // get the connection role, cube and schema reader
    RoleImpl connRole = (RoleImpl) monConnection.getRole();
    //connRole.makeMutableClone();
      logger.debug("DataSecurityManager::setMondrianRole:connection role retrived: " + connRole);
      Query monQuery = monConnection.parseQuery(query);
      Cube cube = monQuery.getCube();
      logger.debug("DataSecurityManager::setMondrianRole: cube retrived: " + cube);
      SchemaReader schemaReader = cube.getSchemaReader(null);
      logger.debug("DataSecurityManager::setMondrianRole: schema reader retrived: " + schemaReader);
   
View Full Code Here

Examples of mondrian.olap.Connection.parseQuery()

    logger.debug("IN");
    StringBuffer buffer = new StringBuffer("parent.execCrossNavigation(window.name, '"
        + StringEscapeUtils.escapeJavaScript(target.documentLabel) + "', '");
    String query = model.getCurrentMdx();
    Connection monConnection = model.getConnection();
      Query monQuery = monConnection.parseQuery(query);
      Cube cube = monQuery.getCube();
     
      List<TargetParameter> parameters = target.parameters;
      if (!parameters.isEmpty()) {
        for (int i = 0; i < parameters.size(); i++) {
View Full Code Here

Examples of mondrian.rolap.RolapConnection.parseQuery()

        propSaver.set(props.ReadAggregates, true);
        propSaver.set(props.GenerateAggregateSql, true);

        final RolapConnection rolapConn = (RolapConnection) getConnection();
        Query query =
            rolapConn.parseQuery(
                "select {[Measures].[Count]} on columns from [HR]");
        rolapConn.execute(query);

        logger.removeAppender(myAppender);
View Full Code Here

Examples of org.apache.phoenix.parse.SQLParser.parseQuery()

        assertEquals(1, joinTable.getJoinSpecs().get(1).getJoinTable().getTable().getPreFilters().size());
    }
   
    private static JoinTable getJoinTable(String query, PhoenixConnection connection) throws SQLException {
        SQLParser parser = new SQLParser(query);
        SelectStatement select = SubselectRewriter.flatten(parser.parseQuery(), connection);
        ColumnResolver resolver = FromCompiler.getResolverForQuery(select, connection);
        select = StatementNormalizer.normalize(select, resolver);
        PhoenixStatement stmt = connection.createStatement().unwrap(PhoenixStatement.class);
        return JoinCompiler.compile(stmt, select, resolver);       
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.