Skip to content

Commit

Permalink
📝 JSONCompactEachRowWithNames Formatter (#134)
Browse files Browse the repository at this point in the history
* 📝 JSONCompactEachRowWithNames Formatter

Signed-off-by: Julio Jimenez <[email protected]>

* README

Signed-off-by: Julio Jimenez <[email protected]>

* jsoncompacteachrowwithnames

Signed-off-by: Julio Jimenez <[email protected]>

---------

Signed-off-by: Julio Jimenez <[email protected]>
  • Loading branch information
juliojimenez committed Feb 19, 2023
1 parent 6ddf78e commit f2e0c48
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 3 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -221,6 +221,7 @@ clickhouse-cl supports automatic input and output format processing for the form
| [JSONStringsEachRow](https://clickhouse.com/docs/en/interfaces/formats/#jsonstringseachrow) | :heavy_check_mark: | :heavy_check_mark: | BOOST-JSON:JSON-OBJECT | jget *obj* *key* |
| [JSONStringsEachRowWithProgress](https://clickhouse.com/docs/en/interfaces/formats/#jsonstringseachrowwithprogress) || :heavy_check_mark: | BOOST-JSON:JSON-OBJECT | jget *obj* *key* |
| [JSONCompactEachRow](https://clickhouse.com/docs/en/interfaces/formats/#jsoncompacteachrow) | :heavy_check_mark: | :heavy_check_mark: | BOOST-JSON:JSON-OBJECT | jget *obj* *key* |
| [JSONCompactEachRowWithNames](https://clickhouse.com/docs/en/interfaces/formats/#jsoncompacteachrowwithnames) | :heavy_check_mark: | :heavy_check_mark: | BOOST-JSON:JSON-OBJECT | jget *obj* *key* |
| [Pretty](https://clickhouse.com/docs/en/interfaces/formats/#pretty) || :heavy_check_mark: || Best viewed with `:console t` |

### Functions
Expand Down
2 changes: 1 addition & 1 deletion clickhouse-test.asd
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
:description "clickhouse Tests"
:author "[email protected]"
:license "Apache-2.0"
:version "0.0.22"
:version "0.0.23"
:depends-on (#:clickhouse
#:fiveam)
:components ((:module "t"
Expand Down
2 changes: 1 addition & 1 deletion clickhouse.asd
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
:description "Common Lisp ClickHouse Client Library"
:author "[email protected]"
:license "Apache-2.0"
:version "0.16.0"
:version "0.17.0"
:depends-on (#:boost-json
#:dexador
#:lexer
Expand Down
1 change: 1 addition & 0 deletions src/ch-sql-parser.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -282,6 +282,7 @@
((equal chosen-format "JSONStringsEachRow") (setf *format* 'jsonstringseachrow))
((equal chosen-format "JSONStringsEachRowWithProgress") (setf *format* 'jsonstringseachrowwithprogress))
((equal chosen-format "JSONCompactEachRow") (setf *format* 'jsoncompacteachrow))
((equal chosen-format "JSONCompactEachRowWithNames") (setf *format* 'jsoncompacteachrowwithnames))
((equal chosen-format "Pretty") (setf *format* 'pretty))
((equal chosen-format "TabSeparated") (setf *format* 'tabseparated))
((equal chosen-format "TabSeparatedRaw") (setf *format* 'tabseparatedraw))
Expand Down
3 changes: 2 additions & 1 deletion src/utils.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,8 @@
(equalp formatting clickhouse.ch-sql-parser::'jsoneachrowwithprogress)
(equalp formatting clickhouse.ch-sql-parser::'jsonstringseachrow)
(equalp formatting clickhouse.ch-sql-parser::'jsonstringseachrowwithprogress)
(equalp formatting clickhouse.ch-sql-parser::'jsoncompacteachrow))
(equalp formatting clickhouse.ch-sql-parser::'jsoncompacteachrow)
(equalp formatting clickhouse.ch-sql-parser::'jsoncompacteachrowwithnames))
(jsoneachrow-formats b))
((equalp formatting clickhouse.ch-sql-parser::'pretty)
(pretty-formatter b))
Expand Down

0 comments on commit f2e0c48

Please sign in to comment.