---
source: crates/squawk_parser/tests/tests.rs
input_file: crates/squawk_parser/tests/data/ok/alter_sequence.sql
---
SOURCE_FILE
  COMMENT "-- full"
  WHITESPACE "\n"
  ALTER_SEQUENCE
    ALTER_KW "alter"
    WHITESPACE " "
    SEQUENCE_KW "sequence"
    WHITESPACE " "
    IF_EXISTS
      IF_KW "if"
      WHITESPACE " "
      EXISTS_KW "exists"
    WHITESPACE " "
    PATH
      PATH
        PATH_SEGMENT
          NAME_REF
            IDENT "foo"
      DOT "."
      PATH_SEGMENT
        NAME_REF
          IDENT "s"
    WHITESPACE "\n  "
    SEQUENCE_OPTION
      AS_KW "as"
      WHITESPACE " "
      CHAR_TYPE
        VARCHAR_KW "varchar"
        ARG_LIST
          L_PAREN "("
          ARG
            LITERAL
              INT_NUMBER "100"
          R_PAREN ")"
    WHITESPACE "\n  "
    SEQUENCE_OPTION
      INCREMENT_KW "increment"
      WHITESPACE " "
      BY_KW "by"
      WHITESPACE " "
      LITERAL
        INT_NUMBER "2"
    WHITESPACE "\n  "
    SEQUENCE_OPTION
      MINVALUE_KW "minvalue"
      WHITESPACE " "
      LITERAL
        INT_NUMBER "1"
    WHITESPACE "\n  "
    SEQUENCE_OPTION
      NO_KW "no"
      WHITESPACE " "
      MINVALUE_KW "minvalue"
    WHITESPACE "\n  "
    SEQUENCE_OPTION
      MAXVALUE_KW "maxvalue"
      WHITESPACE " "
      LITERAL
        INT_NUMBER "100"
    WHITESPACE "\n  "
    SEQUENCE_OPTION
      NO_KW "no"
      WHITESPACE " "
      MAXVALUE_KW "maxvalue"
    WHITESPACE "\n  "
    SEQUENCE_OPTION
      START_KW "start"
      WHITESPACE " "
      LITERAL
        INT_NUMBER "10"
    WHITESPACE "\n  "
    SEQUENCE_OPTION
      START_KW "start"
      WHITESPACE " "
      WITH_KW "with"
      WHITESPACE " "
      LITERAL
        INT_NUMBER "10"
    WHITESPACE "\n  "
    SEQUENCE_OPTION
      RESTART_KW "restart"
    WHITESPACE "\n  "
    SEQUENCE_OPTION
      RESTART_KW "restart"
      WHITESPACE " "
      LITERAL
        INT_NUMBER "10"
    WHITESPACE "\n  "
    SEQUENCE_OPTION
      RESTART_KW "restart"
      WHITESPACE " "
      WITH_KW "with"
      WHITESPACE " "
      LITERAL
        INT_NUMBER "10"
    WHITESPACE "\n  "
    SEQUENCE_OPTION
      CACHE_KW "cache"
      WHITESPACE " "
      LITERAL
        INT_NUMBER "10"
    WHITESPACE "\n  "
    SEQUENCE_OPTION
      NO_KW "no"
      WHITESPACE " "
      CYCLE_KW "cycle"
    WHITESPACE "\n  "
    SEQUENCE_OPTION
      CYCLE_KW "cycle"
    WHITESPACE "\n  "
    SEQUENCE_OPTION
      OWNED_KW "owned"
      WHITESPACE " "
      BY_KW "by"
      WHITESPACE " "
      PATH
        PATH
          PATH_SEGMENT
            NAME_REF
              IDENT "foo"
        DOT "."
        PATH_SEGMENT
          NAME_REF
            IDENT "c"
    WHITESPACE "\n  "
    SEQUENCE_OPTION
      OWNED_KW "owned"
      WHITESPACE " "
      BY_KW "by"
      WHITESPACE " "
      NONE_KW "none"
  SEMICOLON ";"
  WHITESPACE "\n\n"
  COMMENT "-- set_logged"
  WHITESPACE "\n"
  ALTER_SEQUENCE
    ALTER_KW "alter"
    WHITESPACE " "
    SEQUENCE_KW "sequence"
    WHITESPACE " "
    PATH
      PATH_SEGMENT
        NAME_REF
          IDENT "s"
    WHITESPACE "\n  "
    SET_KW "set"
    WHITESPACE " "
    LOGGED_KW "logged"
  SEMICOLON ";"
  WHITESPACE "\n\n"
  ALTER_SEQUENCE
    ALTER_KW "alter"
    WHITESPACE " "
    SEQUENCE_KW "sequence"
    WHITESPACE " "
    PATH
      PATH_SEGMENT
        NAME_REF
          IDENT "s"
    WHITESPACE "\n  "
    SET_KW "set"
    WHITESPACE " "
    UNLOGGED_KW "unlogged"
  SEMICOLON ";"
  WHITESPACE "\n\n"
  COMMENT "-- owner_to"
  WHITESPACE "\n"
  ALTER_SEQUENCE
    ALTER_KW "alter"
    WHITESPACE " "
    SEQUENCE_KW "sequence"
    WHITESPACE " "
    PATH
      PATH_SEGMENT
        NAME_REF
          IDENT "s"
    WHITESPACE "\n  "
    OWNER_TO
      OWNER_KW "owner"
      WHITESPACE " "
      TO_KW "to"
      WHITESPACE " "
      ROLE_REF
        NAME_REF
          IDENT "u"
  SEMICOLON ";"
  WHITESPACE "\n\n"
  ALTER_SEQUENCE
    ALTER_KW "alter"
    WHITESPACE " "
    SEQUENCE_KW "sequence"
    WHITESPACE " "
    PATH
      PATH_SEGMENT
        NAME_REF
          IDENT "s"
    WHITESPACE "\n  "
    OWNER_TO
      OWNER_KW "owner"
      WHITESPACE " "
      TO_KW "to"
      WHITESPACE " "
      ROLE_REF
        CURRENT_USER_KW "current_user"
  SEMICOLON ";"
  WHITESPACE "\n\n"
  COMMENT "-- rename"
  WHITESPACE "\n"
  ALTER_SEQUENCE
    ALTER_KW "alter"
    WHITESPACE " "
    SEQUENCE_KW "sequence"
    WHITESPACE " "
    PATH
      PATH_SEGMENT
        NAME_REF
          IDENT "s"
    WHITESPACE "\n  "
    RENAME_TO
      RENAME_KW "rename"
      WHITESPACE " "
      TO_KW "to"
      WHITESPACE " "
      NAME
        IDENT "t"
  SEMICOLON ";"
  WHITESPACE "\n\n"
  COMMENT "-- schema"
  WHITESPACE "\n"
  ALTER_SEQUENCE
    ALTER_KW "alter"
    WHITESPACE " "
    SEQUENCE_KW "sequence"
    WHITESPACE " "
    PATH
      PATH_SEGMENT
        NAME_REF
          IDENT "s"
    WHITESPACE "\n  "
    SET_SCHEMA
      SET_KW "set"
      WHITESPACE " "
      SCHEMA_KW "schema"
      WHITESPACE " "
      NAME_REF
        IDENT "x"
  SEMICOLON ";"
  WHITESPACE "\n\n"
