GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — [BUG] JSqlParser 5.4: ParseException on recursive CTE selecting a NUMBER column · Issue #2880 · JSQLParser/JSqlParser Open DescriptionFailing SQL Feature:JSqlParser 5.4 fails to parse the following The reported error is at a comma in the select list, immediately after the unqualified column name SQL Example:WITH RECURSIVE
cte_name AS (
SELECT
ID,
PARENT_ID,
NUMBER,
TITLE,
MODEL_TYPE_ID,
TYPE_CLASSIFY,
PRIORITY,
STATE,
DEMAND_CLASSIFY,
PROJECT_ID,
CREATED_USER,
CREATED_TIME
FROM
T_ISSUE
WHERE
ID IN ('xxx')
UNION ALL
SELECT
l.ID,
l.PARENT_ID,
l.NUMBER,
l.TITLE,
l.MODEL_TYPE_ID,
l.TYPE_CLASSIFY,
l.PRIORITY,
l.STATE,
l.DEMAND_CLASSIFY,
l.PROJECT_ID,
l.CREATED_USER,
l.CREATED_TIME
FROM
T_ISSUE l
JOIN cte_name r ON l.PARENT_ID = r.ID
)
SELECT
*
FROM
cte_nameActual behavior:Parsing fails with the following exception (line and column refer to the original input formatting): Expected behavior:The query should parse successfully, treating Reproduction:Save the SQL above as import java.nio.file.Files; import java.nio.file.Path; import net.sf.jsqlparser.parser.CCJSqlParserUtil; String sql = Files.readString(Path.of("query.sql")); CCJSqlParserUtil.parse(sql); Software Information:
Could you check why this query is rejected in 5.4? Activity
MetadataMetadataAssigneesLabelsNo labels TypeProjectsMilestoneRelationshipsDevelopmentIssue actions |
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |