Examples of QuerySpecification


Examples of com.facebook.presto.sql.tree.QuerySpecification

        String queryPlan = getQueryPlan(node, planType, planFormat);

        Query query = new Query(
                Optional.<With>absent(),
                new QuerySpecification(
                        selectList(
                                new SingleColumn(new StringLiteral(queryPlan), "Query Plan")),
                        null,
                        Optional.<Expression>absent(),
                        ImmutableList.<Expression>of(),
View Full Code Here

Examples of com.facebook.presto.sql.tree.QuerySpecification

            predicate = logicalAnd(predicate, likePredicate);
        }

        Query query = new Query(
                Optional.<With>absent(),
                new QuerySpecification(
                        selectList(aliasedName("table_name", "Table")),
                        table(QualifiedName.of(catalogName, TABLE_TABLES.getSchemaName(), TABLE_TABLES.getTableName())),
                        Optional.of(predicate),
                        ImmutableList.<Expression>of(),
                        Optional.<Expression>absent(),
View Full Code Here

Examples of com.facebook.presto.sql.tree.QuerySpecification

    @Override
    protected TupleDescriptor visitShowSchemas(ShowSchemas node, AnalysisContext context)
    {
        Query query = new Query(
                Optional.<With>absent(),
                new QuerySpecification(
                        selectList(aliasedName("schema_name", "Schema")),
                        table(QualifiedName.of(node.getCatalog().or(session.getCatalog()), TABLE_SCHEMATA.getSchemaName(), TABLE_SCHEMATA.getTableName())),
                        Optional.<Expression>absent(),
                        ImmutableList.<Expression>of(),
                        Optional.<Expression>absent(),
View Full Code Here

Examples of com.facebook.presto.sql.tree.QuerySpecification

    @Override
    protected TupleDescriptor visitShowCatalogs(ShowCatalogs node, AnalysisContext context)
    {
        Query query = new Query(
                Optional.<With>absent(),
                new QuerySpecification(
                        selectList(aliasedName("catalog_name", "Catalog")),
                        table(QualifiedName.of(session.getCatalog(), CATALOG_TABLE_NAME.getSchemaName(), CATALOG_TABLE_NAME.getTableName())),
                        Optional.<Expression>absent(),
                        ImmutableList.<Expression>of(),
                        Optional.<Expression>absent(),
View Full Code Here

Examples of com.facebook.presto.sql.tree.QuerySpecification

            throw new SemanticException(MISSING_TABLE, showColumns, "Table '%s' does not exist", tableName);
        }

        Query query = new Query(
                Optional.<With>absent(),
                new QuerySpecification(
                        selectList(
                                aliasedName("column_name", "Column"),
                                aliasedName("data_type", "Type"),
                                aliasedYesNoToBoolean("is_nullable", "Null"),
                                aliasedYesNoToBoolean("is_partition_key", "Partition Key")),
View Full Code Here

Examples of org.qi4j.api.query.grammar.QuerySpecification

*/
public class SolrExpressions
{
    public static QuerySpecification search(String queryString)
    {
        return new QuerySpecification( "solr", queryString );
    }
View Full Code Here

Examples of org.qi4j.api.query.grammar.QuerySpecification

    @Override
    public Iterable<EntityReference> findEntities( Class<?> resultType, @Optional Specification<Composite> whereClause, @Optional OrderBy[] orderBySegments, @Optional Integer firstResult, @Optional Integer maxResults, Map<String, Object> variables ) throws EntityFinderException
    {
        try
        {
            QuerySpecification expr = (QuerySpecification) whereClause;

            SolrServer server = solr.solrServer();

            NamedList<Object> list = new NamedList<Object>();

            list.add( "q", expr.query() );
            list.add( "rows", maxResults != 0 ? maxResults : 10000 );
            list.add( "start", firstResult );

            if( orderBySegments != null && orderBySegments.length > 0 )
            {
View Full Code Here

Examples of org.qi4j.api.query.grammar.QuerySpecification

*/
public class SesameExpressions
{
    public static QuerySpecification sparql(String sparql)
    {
        return new QuerySpecification("SPARQL", sparql);
    }
View Full Code Here

Examples of org.qi4j.api.query.grammar.QuerySpecification

        return new QuerySpecification("SPARQL", sparql);
    }

    public static QuerySpecification serql(String serql)
    {
        return new QuerySpecification("SERQL", serql);
    }
View Full Code Here

Examples of org.sql.generation.api.grammar.query.QuerySpecification

    {
        // Path: Top.* (star without braces), value = value
        // ASSUMING value is NOT collection (ie, find all entities, which collection property has
        // value x as leaf item,
        // no matter collection depth)
        QuerySpecification contains = this.constructQueryForPredicate(
            predicate, //
            predicate.collectionProperty(), //
            null, //
            null, //
            false, //
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.