Package io.crate.sql.tree

Examples of io.crate.sql.tree.Expression


    private SubscriptContext analyzeSubscript(String expressionString) {
        Analyzer.ParameterContext parameterContext = mock(Analyzer.ParameterContext.class);
        when(parameterContext.getAsSymbol(anyInt())).thenReturn(new Parameter(currentParameter));
        SubscriptContext context = new SubscriptContext(parameterContext);
        Expression expression = SqlParser.createExpression(expressionString);
        expression.accept(visitor, context);
        return context;
    }
View Full Code Here


        String routingValue = null;
        List<Expression> values = node.values();
        List<ColumnIdent> primaryKey = context.table().primaryKey();

        for (int i = 0, valuesSize = values.size(); i < valuesSize; i++) {
            Expression expression = values.get(i);
            Symbol valuesSymbol = process(expression, context);

            // implicit type conversion
            Reference column = context.columns().get(i);
            final ColumnIdent columnIdent = column.info().ident().columnIdent();
View Full Code Here

    protected static NumberOfReplicas extractNumberOfReplicas(
            GenericProperties genericProperties,
            Object[] parameters) {
        Map<String,Expression> properties = genericProperties.properties();
        Expression number_of_replicas = properties.remove("number_of_replicas");

        NumberOfReplicas numberOfReplicas = null;
        if (number_of_replicas != null) {
            try {
                Integer numReplicas = ExpressionToNumberVisitor.convert(number_of_replicas, parameters).intValue();
View Full Code Here

TOP

Related Classes of io.crate.sql.tree.Expression

Copyright © 2018 www.massapicom. 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.