{
    "query": "INSERT INTO table_name WITH cte (col1) AS ( SELECT 1 UNION ALL SELECT 2 ) SELECT col1 FROM cte",
    "lexer": {
        "@type": "PhpMyAdmin\\SqlParser\\Lexer",
        "str": "INSERT INTO table_name WITH cte (col1) AS ( SELECT 1 UNION ALL SELECT 2 ) SELECT col1 FROM cte",
        "len": 94,
        "last": 94,
        "list": {
            "@type": "PhpMyAdmin\\SqlParser\\TokensList",
            "tokens": [
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": "INSERT",
                    "value": "INSERT",
                    "keyword": "INSERT",
                    "type": 1,
                    "flags": 35,
                    "position": 0
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": " ",
                    "value": " ",
                    "keyword": null,
                    "type": 3,
                    "flags": 0,
                    "position": 6
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": "INTO",
                    "value": "INTO",
                    "keyword": "INTO",
                    "type": 1,
                    "flags": 3,
                    "position": 7
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": " ",
                    "value": " ",
                    "keyword": null,
                    "type": 3,
                    "flags": 0,
                    "position": 11
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": "table_name",
                    "value": "table_name",
                    "keyword": "TABLE_NAME",
                    "type": 1,
                    "flags": 1,
                    "position": 12
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": " ",
                    "value": " ",
                    "keyword": null,
                    "type": 3,
                    "flags": 0,
                    "position": 22
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": "WITH",
                    "value": "WITH",
                    "keyword": "WITH",
                    "type": 1,
                    "flags": 3,
                    "position": 23
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": " ",
                    "value": " ",
                    "keyword": null,
                    "type": 3,
                    "flags": 0,
                    "position": 27
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": "cte",
                    "value": "cte",
                    "keyword": null,
                    "type": 0,
                    "flags": 0,
                    "position": 28
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": " ",
                    "value": " ",
                    "keyword": null,
                    "type": 3,
                    "flags": 0,
                    "position": 31
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": "(",
                    "value": "(",
                    "keyword": null,
                    "type": 2,
                    "flags": 16,
                    "position": 32
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": "col1",
                    "value": "col1",
                    "keyword": null,
                    "type": 0,
                    "flags": 0,
                    "position": 33
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": ")",
                    "value": ")",
                    "keyword": null,
                    "type": 2,
                    "flags": 16,
                    "position": 37
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": " ",
                    "value": " ",
                    "keyword": null,
                    "type": 3,
                    "flags": 0,
                    "position": 38
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": "AS",
                    "value": "AS",
                    "keyword": "AS",
                    "type": 1,
                    "flags": 3,
                    "position": 39
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": " ",
                    "value": " ",
                    "keyword": null,
                    "type": 3,
                    "flags": 0,
                    "position": 41
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": "(",
                    "value": "(",
                    "keyword": null,
                    "type": 2,
                    "flags": 16,
                    "position": 42
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": " ",
                    "value": " ",
                    "keyword": null,
                    "type": 3,
                    "flags": 0,
                    "position": 43
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": "SELECT",
                    "value": "SELECT",
                    "keyword": "SELECT",
                    "type": 1,
                    "flags": 3,
                    "position": 44
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": " ",
                    "value": " ",
                    "keyword": null,
                    "type": 3,
                    "flags": 0,
                    "position": 50
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": "1",
                    "value": 1,
                    "keyword": null,
                    "type": 6,
                    "flags": 0,
                    "position": 51
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": " ",
                    "value": " ",
                    "keyword": null,
                    "type": 3,
                    "flags": 0,
                    "position": 52
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": "UNION ALL",
                    "value": "UNION ALL",
                    "keyword": "UNION ALL",
                    "type": 1,
                    "flags": 7,
                    "position": 53
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": " ",
                    "value": " ",
                    "keyword": null,
                    "type": 3,
                    "flags": 0,
                    "position": 62
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": "SELECT",
                    "value": "SELECT",
                    "keyword": "SELECT",
                    "type": 1,
                    "flags": 3,
                    "position": 63
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": " ",
                    "value": " ",
                    "keyword": null,
                    "type": 3,
                    "flags": 0,
                    "position": 69
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": "2",
                    "value": 2,
                    "keyword": null,
                    "type": 6,
                    "flags": 0,
                    "position": 70
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": " ",
                    "value": " ",
                    "keyword": null,
                    "type": 3,
                    "flags": 0,
                    "position": 71
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": ")",
                    "value": ")",
                    "keyword": null,
                    "type": 2,
                    "flags": 16,
                    "position": 72
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": " ",
                    "value": " ",
                    "keyword": null,
                    "type": 3,
                    "flags": 0,
                    "position": 73
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": "SELECT",
                    "value": "SELECT",
                    "keyword": "SELECT",
                    "type": 1,
                    "flags": 3,
                    "position": 74
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": " ",
                    "value": " ",
                    "keyword": null,
                    "type": 3,
                    "flags": 0,
                    "position": 80
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": "col1",
                    "value": "col1",
                    "keyword": null,
                    "type": 0,
                    "flags": 0,
                    "position": 81
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": " ",
                    "value": " ",
                    "keyword": null,
                    "type": 3,
                    "flags": 0,
                    "position": 85
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": "FROM",
                    "value": "FROM",
                    "keyword": "FROM",
                    "type": 1,
                    "flags": 3,
                    "position": 86
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": " ",
                    "value": " ",
                    "keyword": null,
                    "type": 3,
                    "flags": 0,
                    "position": 90
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": "cte",
                    "value": "cte",
                    "keyword": null,
                    "type": 0,
                    "flags": 0,
                    "position": 91
                },
                {
                    "@type": "PhpMyAdmin\\SqlParser\\Token",
                    "token": null,
                    "value": null,
                    "keyword": null,
                    "type": 9,
                    "flags": 0,
                    "position": null
                }
            ],
            "count": 38,
            "idx": 38
        },
        "delimiter": ";",
        "delimiterLen": 1,
        "strict": false,
        "errors": []
    },
    "parser": {
        "@type": "PhpMyAdmin\\SqlParser\\Parser",
        "list": {
            "@type": "@1"
        },
        "statements": [
            {
                "@type": "PhpMyAdmin\\SqlParser\\Statements\\InsertStatement",
                "into": {
                    "@type": "PhpMyAdmin\\SqlParser\\Components\\IntoKeyword",
                    "type": null,
                    "dest": {
                        "@type": "PhpMyAdmin\\SqlParser\\Components\\Expression",
                        "database": null,
                        "table": "table_name",
                        "column": null,
                        "expr": "table_name",
                        "alias": null,
                        "function": null,
                        "subquery": null
                    },
                    "columns": null,
                    "values": null,
                    "fields_options": null,
                    "fields_keyword": null,
                    "lines_options": null
                },
                "values": null,
                "set": null,
                "select": null,
                "with": {
                    "@type": "PhpMyAdmin\\SqlParser\\Statements\\WithStatement",
                    "withers": {
                        "cte": {
                            "@type": "PhpMyAdmin\\SqlParser\\Components\\WithKeyword",
                            "name": "cte",
                            "columns": [
                                {
                                    "@type": "PhpMyAdmin\\SqlParser\\Components\\ArrayObj",
                                    "raw": [
                                        "col1"
                                    ],
                                    "values": [
                                        "col1"
                                    ]
                                }
                            ],
                            "statement": {
                                "@type": "PhpMyAdmin\\SqlParser\\Parser",
                                "list": {
                                    "@type": "PhpMyAdmin\\SqlParser\\TokensList",
                                    "tokens": [
                                        {
                                            "@type": "@19"
                                        },
                                        {
                                            "@type": "@20"
                                        },
                                        {
                                            "@type": "@21"
                                        },
                                        {
                                            "@type": "@22"
                                        },
                                        {
                                            "@type": "@23"
                                        },
                                        {
                                            "@type": "@24"
                                        },
                                        {
                                            "@type": "@25"
                                        },
                                        {
                                            "@type": "@26"
                                        },
                                        {
                                            "@type": "@27"
                                        },
                                        {
                                            "@type": "@28"
                                        },
                                        {
                                            "@type": "@29"
                                        }
                                    ],
                                    "count": 11,
                                    "idx": 11
                                },
                                "statements": [
                                    {
                                        "@type": "PhpMyAdmin\\SqlParser\\Statements\\SelectStatement",
                                        "expr": [
                                            {
                                                "@type": "PhpMyAdmin\\SqlParser\\Components\\Expression",
                                                "database": null,
                                                "table": null,
                                                "column": null,
                                                "expr": "1",
                                                "alias": null,
                                                "function": null,
                                                "subquery": null
                                            }
                                        ],
                                        "from": [],
                                        "index_hints": null,
                                        "partition": null,
                                        "where": null,
                                        "group": null,
                                        "group_options": null,
                                        "having": null,
                                        "order": null,
                                        "limit": null,
                                        "procedure": null,
                                        "into": null,
                                        "join": null,
                                        "union": [
                                            [
                                                "UNION ALL",
                                                {
                                                    "@type": "PhpMyAdmin\\SqlParser\\Statements\\SelectStatement",
                                                    "expr": [
                                                        {
                                                            "@type": "PhpMyAdmin\\SqlParser\\Components\\Expression",
                                                            "database": null,
                                                            "table": null,
                                                            "column": null,
                                                            "expr": "2",
                                                            "alias": null,
                                                            "function": null,
                                                            "subquery": null
                                                        }
                                                    ],
                                                    "from": [],
                                                    "index_hints": null,
                                                    "partition": null,
                                                    "where": null,
                                                    "group": null,
                                                    "group_options": null,
                                                    "having": null,
                                                    "order": [],
                                                    "limit": null,
                                                    "procedure": null,
                                                    "into": null,
                                                    "join": null,
                                                    "union": [],
                                                    "end_options": null,
                                                    "options": {
                                                        "@type": "PhpMyAdmin\\SqlParser\\Components\\OptionsArray",
                                                        "options": []
                                                    },
                                                    "first": 5,
                                                    "last": 10
                                                }
                                            ]
                                        ],
                                        "end_options": null,
                                        "options": {
                                            "@type": "PhpMyAdmin\\SqlParser\\Components\\OptionsArray",
                                            "options": []
                                        },
                                        "first": 0,
                                        "last": 10
                                    }
                                ],
                                "brackets": 0,
                                "strict": false,
                                "errors": []
                            }
                        }
                    },
                    "cteStatementParser": {
                        "@type": "PhpMyAdmin\\SqlParser\\Parser",
                        "list": {
                            "@type": "PhpMyAdmin\\SqlParser\\TokensList",
                            "tokens": [
                                {
                                    "@type": "@32"
                                },
                                {
                                    "@type": "@33"
                                },
                                {
                                    "@type": "@34"
                                },
                                {
                                    "@type": "@35"
                                },
                                {
                                    "@type": "@36"
                                },
                                {
                                    "@type": "@37"
                                },
                                {
                                    "@type": "@38"
                                },
                                {
                                    "@type": "@39"
                                }
                            ],
                            "count": 8,
                            "idx": 8
                        },
                        "statements": [
                            {
                                "@type": "PhpMyAdmin\\SqlParser\\Statements\\SelectStatement",
                                "expr": [
                                    {
                                        "@type": "PhpMyAdmin\\SqlParser\\Components\\Expression",
                                        "database": null,
                                        "table": null,
                                        "column": "col1",
                                        "expr": "col1",
                                        "alias": null,
                                        "function": null,
                                        "subquery": null
                                    }
                                ],
                                "from": [
                                    {
                                        "@type": "PhpMyAdmin\\SqlParser\\Components\\Expression",
                                        "database": null,
                                        "table": "cte",
                                        "column": null,
                                        "expr": "cte",
                                        "alias": null,
                                        "function": null,
                                        "subquery": null
                                    }
                                ],
                                "index_hints": null,
                                "partition": null,
                                "where": null,
                                "group": null,
                                "group_options": null,
                                "having": null,
                                "order": null,
                                "limit": null,
                                "procedure": null,
                                "into": null,
                                "join": null,
                                "union": [],
                                "end_options": null,
                                "options": {
                                    "@type": "PhpMyAdmin\\SqlParser\\Components\\OptionsArray",
                                    "options": []
                                },
                                "first": 0,
                                "last": 6
                            }
                        ],
                        "brackets": 0,
                        "strict": false,
                        "errors": []
                    },
                    "options": {
                        "@type": "PhpMyAdmin\\SqlParser\\Components\\OptionsArray",
                        "options": []
                    },
                    "first": null,
                    "last": null
                },
                "onDuplicateSet": null,
                "options": {
                    "@type": "PhpMyAdmin\\SqlParser\\Components\\OptionsArray",
                    "options": []
                },
                "first": 0,
                "last": 36
            }
        ],
        "brackets": 0,
        "strict": false,
        "errors": []
    },
    "errors": {
        "lexer": [],
        "parser": []
    }
}