struct

Clickhouse::Response

Inherits Enumerable / Struct / Value / Object

Constructors

new(uri : URI, req : Request, http : HTTP::Client::Response, time : Time::Span)
Source

Instance methods

body(*args, **options)
Source
body(*args, **options, &)
Source
clone
Source
copy_with(uri _uri = @uri, req _req = @req, http _http = @http, time _time = @time)
Source
data
data(*args, **options)
Source
data(*args, **options, &)
Source
data=(v : Array(Array(JSON::Any))) : Array(Array(JSON::Any))
data=(v : Nil)

nil assignments are always ignored

data?
each

define 'each' directly since 'delegate' fails

Source
each_hash

TODO: optimize

Source
http
map(*types : *T) forall T
res = execute <<-SQL
  SELECT   engine, count(*)
  FROM     system.tables
  GROUP BY engine
  SQL
records = res.success!.map(String, UInt64)
records.each do |(name, cnt)|
  p [name, cnt]
Source
map
res = execute <<-SQL
  SELECT   engine, count(*)
  FROM     system.tables
  GROUP BY engine
  SQL
records = res.success!.map(name: String, cnt: UInt64)
records.each do |record|
  p [record["name"], record["cnt"]]
Source
meta(*args, **options)
Source
meta(*args, **options, &)
Source
parsed
parsed=(v : JSONCompactParser) : JSONCompactParser
parsed=(v : Nil)

nil assignments are always ignored

parsed?
records
res = execute <<-SQL
  SELECT   engine, count(*)
  FROM     system.tables
  GROUP BY engine
  SQL
records = res.success!.records
records.each do |hash|
  p hash["engine"]
Source
req
rows(*args, **options)
Source
rows(*args, **options, &)
Source
scalar(*args, **options)
Source
scalar(*args, **options, &)
Source
statistics(*args, **options)
Source
statistics(*args, **options, &)
Source
status_code(*args, **options)
Source
status_code(*args, **options, &)
Source
success!
Source
success?
Source
time
to_json
Source
uri

Nested types