<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Go on 静夜思己过 - 猿资猿味 - 高波的博客</title><link>https://gaoboy.com/categories/go/</link><description>Recent content in Go on 静夜思己过 - 猿资猿味 - 高波的博客</description><generator>Hugo</generator><language>zh-cn</language><copyright>&lt;a rel="license noopener" href="https://beian.miit.gov.cn/" target="_blank">浙ICP备14043338号-2&lt;/a>~&lt;a rel="license noopener" href="http://www.beian.gov.cn/portal/registerSystemInfo?recordcode=33010802003111" target="_blank">浙公网安备 33010802003111号&lt;/a></copyright><lastBuildDate>Fri, 20 Jan 2023 20:47:53 +0800</lastBuildDate><atom:link href="https://gaoboy.com/categories/go/index.xml" rel="self" type="application/rss+xml"/><item><title>Go Antlr4 Plsql Sql Parser Demo</title><link>https://gaoboy.com/post/go-antlr4-plsql-sql-parser-demo/</link><pubDate>Fri, 20 Jan 2023 20:47:53 +0800</pubDate><guid>https://gaoboy.com/post/go-antlr4-plsql-sql-parser-demo/</guid><description>&lt;h1 id="准备">准备&lt;/h1>
&lt;h2 id="一-antlrgrammars-v4-下载plsql">一. antlr/grammars-v4 下载plsql&lt;/h2>
&lt;p>&lt;a href="https://github.com/antlr/grammars-v4/tree/master/sql/plsql">https://github.com/antlr/grammars-v4/tree/master/sql/plsql&lt;/a>&lt;/p>
&lt;p>下载2个&lt;code>.g4&lt;/code>的文件&lt;/p>
&lt;p>&lt;a href="https://github.com/antlr/grammars-v4/blob/master/sql/plsql/PlSqlLexer.g4">PlSqlLexer.g4&lt;/a>&lt;/p>
&lt;p>&lt;a href="https://github.com/antlr/grammars-v4/blob/master/sql/plsql/PlSqlParser.g4">PlSqlParser.g4&lt;/a>&lt;/p>
&lt;h2 id="二-下载antlr-4101-completejarhttpswwwantlrorgdownloadantlr-4101-completejar">二. 下载&lt;a href="https://www.antlr.org/download/antlr-4.10.1-complete.jar">antlr-4.10.1-complete.jar&lt;/a>&lt;/h2>
&lt;p>注意运行此&lt;code>jar&lt;/code>包需要&lt;code>jdk11&lt;/code>。&lt;/p>
&lt;p>&lt;strong>截至2023-01-20，antlr-4.11.0-complete.jar及以上版本生成出的parser本人未能修改并成功跑通，多次降低版本至4.10.1才勉强改动后跑起来了，如有纰漏请指正。&lt;/strong>&lt;/p></description></item></channel></rss>