Examples of StatementNode


Examples of org.apache.derby.impl.sql.compile.StatementNode

/*
* <A NAME="createStatements">spsCreateStatement</A>
*/
  final public StatementNode createStatements() throws ParseException, StandardException {
        StatementNode statementNode;
        Token beginToken;
        int tokKind;
    beginToken = jj_consume_token(CREATE);
    switch (jj_nt.kind) {
    case SCHEMA:
View Full Code Here

Examples of org.apache.derby.impl.sql.compile.StatementNode

/*
* <A NAME="dropStatements">spsDropStatement</A>
*/
  final public StatementNode dropStatements() throws ParseException, StandardException {
        StatementNode statementNode;
    jj_consume_token(DROP);
    switch (jj_nt.kind) {
    case SCHEMA:
      statementNode = dropSchemaStatement();
      break;
View Full Code Here

Examples of org.apache.derby.impl.sql.compile.StatementNode

/*
* <A NAME="spsAlterStatement">spsAlterStatement</A>
*/
  final public StatementNode spsAlterStatement() throws ParseException, StandardException {
        StatementNode statementNode;
    jj_consume_token(ALTER);
    statementNode = alterTableStatement();
                {if (true) return statementNode;}
    throw new Error("Missing return statement in function");
  }
View Full Code Here

Examples of org.apache.derby.impl.sql.compile.StatementNode

/*
* <A NAME="spsSetStatement">spsSetStatement</A>
*/
  final public StatementNode spsSetStatement() throws ParseException, StandardException {
        StatementNode statementNode;
    if (getToken(1).kind == SET && getToken(2).kind != CURRENT) {
      jj_consume_token(SET);
      if (jj_2_3(1)) {
        statementNode = setIsolationStatement();
      } else if (jj_2_4(1)) {
View Full Code Here

Examples of org.apache.derby.impl.sql.compile.StatementNode

* supports positioned update and delete
* and a preparable select (with FOR UPDATE)
* instead of a direct select (without FOR UPDATE)
*/
  final public StatementNode preparableSQLDataStatement() throws ParseException, StandardException {
        StatementNode   dmlStatement;
    switch (jj_nt.kind) {
    case DELETE:
      /*
        ** RESOLVE: Ignoring temporary table declarations for now.
        */
 
View Full Code Here

Examples of org.apache.derby.impl.sql.compile.StatementNode

* <A NAME="preparableDeleteStatement">preparableDeleteStatement</A>
*
*  This may be a search or positioned delete statement.
*/
  final public StatementNode preparableDeleteStatement() throws ParseException, StandardException {
        StatementNode qtn;
    jj_consume_token(DELETE);
    qtn = deleteBody();
                {if (true) return qtn;}
    throw new Error("Missing return statement in function");
  }
View Full Code Here

Examples of org.apache.derby.impl.sql.compile.StatementNode

/*
* <A NAME="insertStatement">insertStatement</A>
*/
  final public StatementNode insertStatement() throws ParseException, StandardException {
        StatementNode   insertNode;
        QueryTreeNode   targetTable;
    jj_consume_token(INSERT);
    jj_consume_token(INTO);
    targetTable = targetTable();
    insertNode = insertColumnsAndSource(targetTable);
View Full Code Here

Examples of org.apache.derby.impl.sql.compile.StatementNode

/*
* <A NAME="preparableUpdateStatement">preparableUpdateStatement</A>
*/
  final public StatementNode preparableUpdateStatement() throws ParseException, StandardException {
        StatementNode qtn;
    jj_consume_token(UPDATE);
    qtn = updateBody();
                {if (true) return qtn;}
    throw new Error("Missing return statement in function");
  }
View Full Code Here

Examples of org.apache.derby.impl.sql.compile.StatementNode

/*
* <A NAME="callStatement">callStatement</A>
*/
  final public StatementNode callStatement() throws ParseException, StandardException {
        StatementNode retval;
    switch (jj_nt.kind) {
    case CALL:
    case QUESTION_MARK:
      retval = bareCallStatement();
      break;
View Full Code Here

Examples of org.apache.derby.impl.sql.compile.StatementNode

                        ! (((JavaToSQLValueNode) value).getJavaValueNode() instanceof MethodCallNode))
                {
                        {if (true) throw StandardException.newException(SQLState.LANG_INVALID_CALL_STATEMENT);}
                }

                StatementNode callStatement =
                                                                        (StatementNode) nodeFactory.getNode(
                                                                                                C_NodeTypes.CALL_STATEMENT_NODE,
                                                                                                value,
                                                                                                getContextManager());

                setUpAndLinkParameters();

                {if (true) return callStatement;}
      break;
    case QUESTION_MARK:
      returnParam = dynamicParameterSpecification();
                getCompilerContext().setReturnParameterFlag(); //bug4450

      jj_consume_token(EQUALS_OPERATOR);
      jj_consume_token(CALL);
      resultSetNode = rowValueConstructor(null);
                // validate that we have something that is an appropriate call statement
                ResultColumnList rcl = resultSetNode.getResultColumns();

                // we can have only 1 return value/column
                if (rcl == null || rcl.size() > 1)
                {
                        {if (true) throw StandardException.newException(SQLState.LANG_INVALID_CALL_STATEMENT);}
                }

                // we must have a method call node
                value = ((ResultColumn) rcl.elementAt(0)).getExpression();
                if (! (value instanceof JavaToSQLValueNode) ||
                        ! (((JavaToSQLValueNode) value).getJavaValueNode() instanceof MethodCallNode))
                {
                        {if (true) throw StandardException.newException(SQLState.LANG_INVALID_CALL_STATEMENT);}
                }

                // wrap the row result set in a cursor node
                StatementNode cursorNode =
                                        (StatementNode) nodeFactory.getNode(
                                                C_NodeTypes.CURSOR_NODE,
                                                "SELECT",
                                                resultSetNode,
                                                null,
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.