skip to Main Content

JSON array to rows in ClickHouse

What query would transpose the following JSON value to multiple rows. Examples with nested JSON objects are sparse. [{"a":{"b":"val", "c":1}},{"a":{"b":"val", "c":4}}] Tried combinations of JSONExtract but having difficulty with nested object

VIEW QUESTION

JSON parsing removes decimal trailing zeros

I have a Json string, after parsing I want it to remain in decimal form. import play.api.libs.json._ val jsonString = """{"value":2.0}""" println(jsonString) println(Json.parse(jsonString)) The output of the code above is: {"value":2.0} {"value":2} I need it to be {"value":2.0} {"value":2.0}

VIEW QUESTION

Json – Create a hash of arrays from CSV with jq

I have the following CSV (truncated): "adfebb","a-f-A-M-F-R-Z","95-00123","C560","USAF" "ae0133","a-f-A-M-F-R-Z","97-00102","C560","USAF" I need the following JSON: { "adfebb":["a-f-A-M-F-R-Z","95-00123","C560","USAF"], "ae0133":["a-f-A-M-F-R-Z","97-00102","C560","USAF"] } I have been tinkering with jq and came close but I haven't managed to get it just right. What I currently have is:…

VIEW QUESTION
Back To Top
Search