influxdb/services
Jonathan A. Sternberg d7c8c7ca4f Support subquery execution in the query language
This adds query syntax support for subqueries and adds support to the
query engine to execute queries on subqueries.

Subqueries act as a source for another query. It is the equivalent of
writing the results of a query to a temporary database, executing
a query on that temporary database, and then deleting the database
(except this is all performed in-memory).

The syntax is like this:

    SELECT sum(derivative) FROM (SELECT derivative(mean(value)) FROM cpu GROUP BY *)

This will execute derivative and then sum the result of those derivatives.
Another example:

    SELECT max(min) FROM (SELECT min(value) FROM cpu GROUP BY host)

This would let you find the maximum minimum value of each host.

There is complete freedom to mix subqueries with auxiliary fields. The only
caveat is that the following two queries:

    SELECT mean(value) FROM cpu
    SELECT mean(value) FROM (SELECT value FROM cpu)

Have different performance characteristics. The first will calculate
`mean(value)` at the shard level and will be faster, especially when it comes to
clustered setups. The second will process the mean at the top level and will not
include that optimization.
2017-01-07 13:00:48 -06:00
..
admin Use proper uber-go/zap import path 2016-12-15 08:54:14 -06:00
collectd Update godoc for services 2016-12-30 18:03:01 -08:00
continuous_querier Update godoc for services 2016-12-30 18:03:01 -08:00
graphite Merge remote-tracking branch 'influx/master' into mr-godoc 2017-01-04 13:27:36 -08:00
httpd Update godoc for services 2016-12-30 18:03:01 -08:00
meta Support subquery execution in the query language 2017-01-07 13:00:48 -06:00
opentsdb Update godoc for services 2016-12-30 18:03:01 -08:00
precreator Update godoc for services 2016-12-30 18:03:01 -08:00
retention Update godoc for services 2016-12-30 18:03:01 -08:00
snapshotter Update godoc for services 2016-12-30 18:03:01 -08:00
subscriber Update godoc for services 2016-12-30 18:03:01 -08:00
udp Update godoc for services 2016-12-30 18:03:01 -08:00