go-clickhouse icon indicating copy to clipboard operation
go-clickhouse copied to clipboard

Extremes and WITH TOTALS support

Open blide opened this issue 9 years ago • 3 comments

Currently Iter.Scan() breaks on the first empty line and misses extremes and WITH TOTALS rows which separated from the main data by an empty line. https://clickhouse.yandex/reference_en.html#TabSeparated I see 2 ways:

  1. Include additional data by default
  2. Add flag Iter.SetAdditionalData(bool)

blide avatar Jan 20 '17 09:01 blide

I have no time to implement it right now, but pull requests are welcome, I'll leave this issue open.

m1nor avatar Jan 29 '17 16:01 m1nor

@m1nor which way would you prefer?

blide avatar Jan 29 '17 16:01 blide

I think explicit variant is preferable, let's add func (i *Iter) SetOptions(opt IterOptions)

m1nor avatar Jan 31 '17 13:01 m1nor