got it. first(), last() will do.
On Thursday, June 30, 2016 at 5:53:28 PM UTC-7, Kenneth Ho wrote: > > hi all, > i am interested in feeding read time stock tick into influxDB and then > trigger a CQ to aggregate them into minute candle (OHLC) > > The schema for storing the incoming tick will be: > > measurement : Stock > Tag : symbol > field: price, size, flag > > > The query will be something like: > select min(price), max(price), sum(size) from Stock where time >= now() - > 1s group by ticker, time(1s) > > min(price) , max(price) takes care of High, Low of the candle for that > minute, > how do i get the Open, Close? > > > Thanks for your help. > > --ken > -- Remember to include the InfluxDB version number with all issue reports --- You received this message because you are subscribed to the Google Groups "InfluxDB" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/influxdb. To view this discussion on the web visit https://groups.google.com/d/msgid/influxdb/54d5402b-a48e-4644-b5c9-7704478de27f%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
