loopbackio / loopbackio/loopback-connector-sqlite3
REQ: JSON query using the extract (->) operator
まだ誰も着手していません。
- 主要言語
- JavaScript
- スター
- 13
- フォーク
- 21
- PR マージ指標
- 30日以内にマージされた PR はありません
説明
Bug or feature request
- Bug
- Feature request
Description of feature (or steps to reproduce if bug)
SQLite3 3.38 of Feb 2022 has support for json extract -> not unlike Postgres and MySQL. This connector should be updated to use that if possible.
- SQLite documentation: https://www.sqlite.org/json1.html#jptr
- loopback-connector-postgresql commit: https://github.com/loopbackio/loopback-connector-postgresql/commit/d9121644abe667a2b7d7244068d99b81b593effe
No data type change is needed -- it's still TEXT.
Expected result
I hope the final interface is the same as the Postgres connector. The PG example is:
Customer.find({
where: {
'address.state': 'California'
},
order: 'address.city'
})
Additional information (Node.js version, LoopBack version, etc)
Eh, doesn't really matter here. No code for this stuff present is no code for this stuff present.
It's also not like people use loopback with sqlite3 for super serious business things, so don't put the priority too high. It's just nice to make it capable of this JSON stuff so people can experiment on a minimal setup.
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
SQLite JSON1 のドキュメントと、リンクされている loopback-connector-postgresql のコミットから始めてください。このコネクタが、要求された Customer の where と order の例に対して、ネストされた JSON パスをどのように処理するかを追跡し、その後、値が TEXT のままで JSON 抽出が機能することを確認してください。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- javascript, sqlite
- 領域
- database
- issue の種類
- 機能追加
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 35/100