Skip to content

Commit

Permalink
Update clickhouse_query.flux
Browse files Browse the repository at this point in the history
Signed-off-by: Lorenzo Mangani <[email protected]>
  • Loading branch information
lmangani authored Apr 15, 2023
1 parent 8fb0adf commit f09eadf
Showing 1 changed file with 3 additions and 8 deletions.
11 changes: 3 additions & 8 deletions scripts/clickhouse_query.flux
Original file line number Diff line number Diff line change
@@ -1,10 +1,5 @@
import "csv"
import "experimental/http/requests"
import "strings"
import "contrib/qxip/clickhouse"

url = "https://[email protected]"
query = "SELECT 'hello' as _value, 100 as _data FORMAT CSVWithNames"
response = requests.get(url:url, params: ["query": [query]])
option clickhouse.defaultURL = "https://demo:[email protected]:8443"

csv.from(csv: string(v: response.body), mode: "raw")
|> keep(columns: ["_value","_data"])
clickhouse.query(query: "SELECT version()")

0 comments on commit f09eadf

Please sign in to comment.