dt-sql-parser
dt-sql-parser copied to clipboard
SQL Parsers for BigData, built with antlr4.
 这里的assert 和 util指的是什么
## 简介 https://github.com/DTStack/dt-sql-parser/issues/247 指定 parser 解析模式为 `PredictionMode.SLL`,以获得更好的性能。 SLL 拥有更好的性能的同时,也对语法文件有更高的要求,它要求 1. 语法文件的规则尽量简洁(减少前缀相同的备选分支) 2. 语法文件内部规则没有很高的模糊性(二义性) 3. 尽量少的使用左递归 ## 主要变更 1. basicParser 中为 parser 设置解析模式为 `PredictionMode.SLL` 4. 优化 mysql、spark 以及 postgre 的语法文件,以适应 SLL...
## 简介 支持上下文中的实体收集 #250 ## 主要变更 1. 新增entityCollector 抽象类 2. 重命名 SyntaxContextType 为 EntitContextType 3. 添加单元测试 ## 支持情况 - [X] MySQL @HaydenOrz - [X] Spark @HaydenOrz - [X] Impala @LuckyFBB...
Bumps [semver](https://github.com/npm/node-semver) from 5.7.1 to 5.7.2. Release notes Sourced from semver's releases. v5.7.2 5.7.2 (2023-07-10) Bug Fixes 2f8fd41 #585 better handling of whitespace (#585) (@joaomoreno, @lukekarrys) Changelog Sourced from semver's...
Bumps [word-wrap](https://github.com/jonschlinkert/word-wrap) from 1.2.3 to 1.2.5. Release notes Sourced from word-wrap's releases. 1.2.5 Changes: Reverts default value for options.indent to two spaces ' '. Full Changelog: https://github.com/jonschlinkert/word-wrap/compare/1.2.4...1.2.5 1.2.4 What's Changed...
### Topic Any Others ### Description https://github.com/mike-lischke/antlr4ng
**Version** v4.0.0-beta.4.3 **The Type of SQL** SparkSQL **Your Code** 一个 1800+ 行的 sql **Problem** 1800+ 行 sql 的 validate 和 parse 产生长任务 2.15s,时间有点长。
**Version** e.g. v4.0.0-beta.4.10 **The Type of SQL** mysql **Your Code** sql语句为:let text = SELECT * FROM current_catalog_schema1 as let position = {lineNumber: 1, column: 41} **Problem** 调用parser.getSuggestionAtCaretPosition(text, position)获取当前节点的语义信息; 结果如下: ```js...
nonReserved keywords is contained by idetifier rule