apache / apache/datafusion-sqlparser-rs

Implement SQL writer

オープン
#18 コメント 10 件 リアクション 9 件 担当者 0 名 GitHub で見る
主要言語
Rust
スター
3.5k
フォーク
772
平均マージ
4日 9時間
マージ済み PR(30日)
17

説明

It is often useful to be able to generate SQL from the AST. This opens up possibilities for SQL manipulation or translation. The write should recursively walk the AST and write SQL to a writer / output stream.

A secondary benefit of having a writer is that it often simplifies writing unit tests for the parser, since a SQL statement can be parsed and re-written and then the output can be compared with the input (ignoring whitespace differences)

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

調査の方向性

ファイルパスもテストパスも指定されていません。まず AST の定義と parser のエントリポイントを見つけ、次に既存の parser の単体テストを調べます。完了条件は、解析された AST を writer または出力ストリーム経由で SQL として再帰的に書き出し、空白の違いを無視して解析した文と書き直した文を比較するラウンドトリップテストを用意することです。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
rust, sql
領域
compilers, databases
issue の種類
機能追加
難易度
5/5
見積もり時間
1週間以上
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
35/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。