java.lang.Object
org.pgcodekeeper.core.database.pg.parser.rulectx.PgSelectOps

public class PgSelectOps extends Object
Merging wrapper for select_ops/select_ops_no_parens. Provides a unified interface for working with PostgreSQL SELECT operations that may or may not be parenthesized.
Author:
levsha_aa
  • Constructor Details

    • PgSelectOps

      public PgSelectOps(SQLParser.Select_opsContext ops)
      Creates a wrapper for parenthesized SELECT operations.
      Parameters:
      ops - the SELECT operations context with parentheses
    • PgSelectOps

      public PgSelectOps(SQLParser.Select_ops_no_parensContext ops)
      Creates a wrapper for non-parenthesized SELECT operations.
      Parameters:
      ops - the SELECT operations context without parentheses
  • Method Details

    • leftParen

      public org.antlr.v4.runtime.tree.TerminalNode leftParen()
      Returns the left parenthesis terminal node if present.
      Returns:
      the left parenthesis node or null if not present
    • rightParen

      public org.antlr.v4.runtime.tree.TerminalNode rightParen()
      Returns the right parenthesis terminal node if present.
      Returns:
      the right parenthesis node or null if not present
    • selectStmt

      public SQLParser.Select_stmtContext selectStmt()
      Returns the SELECT statement context.
      Returns:
      the SELECT statement context or null for non-parenthesized operations
    • selectOps

      public PgSelectOps selectOps(int i)
      Returns a SELECT operations wrapper for the specified index.
      Parameters:
      i - the index of the SELECT operations
      Returns:
      SELECT operations wrapper or null if not found
    • intersect

      public org.antlr.v4.runtime.tree.TerminalNode intersect()
      Returns the INTERSECT terminal node if present.
      Returns:
      the INTERSECT node or null if not present
    • union

      public org.antlr.v4.runtime.tree.TerminalNode union()
      Returns the UNION terminal node if present.
      Returns:
      the UNION node or null if not present
    • except

      public org.antlr.v4.runtime.tree.TerminalNode except()
      Returns the EXCEPT terminal node if present.
      Returns:
      the EXCEPT node or null if not present
    • setQualifier

      public SQLParser.Set_qualifierContext setQualifier()
      Returns the set qualifier context (ALL, DISTINCT).
      Returns:
      the set qualifier context or null if not present
    • selectPrimary

      public SQLParser.Select_primaryContext selectPrimary()
      Returns the SELECT primary context.
      Returns:
      the SELECT primary context or null if not present