Support the `now()` function in query select and where clause (#1631)
Support the `now()` function in query select and where clause (#1631)

* GROUP BY time function.
* Add a 'time' column for each time function used in the GROUP BY clause.
* Merge branch 'riak_ts-integration' of https://github.com/basho/riak_kv into at-group-by-time

Conflicts:
	src/riak_kv_qry_compiler.erl
* Dialyzer fixes.
* Merge branch 'riak_ts-integration' of https://github.com/basho/riak_kv into at-group-by-time

Conflicts:
	src/riak_kv_qry_compiler.erl
* time/2 working in the select clause.
* Type checking in the time/2 function used in the select clause.
* Check that columns used in the group by clause exist.
* Merge branch 'at-group-by-time' of https://github.com/basho/riak_kv into at-now-in-where-clause
* now() function in the where clause
* Validate arity of now() in the where clause.
* Support now() in the select clause.
* Merge branch 'at-arithmetic-in-where-clause' of https://github.com/basho/riak_kv into at-now-in-where

Conflicts:
	src/riak_kv_qry_compiler.erl
* Merge branch 'riak_ts-develop' of https://github.com/basho/riak_kv into at-now-in-where

Conflicts:
	src/riak_kv_qry_compiler.erl
* Added a unit test for addition and multiplication involving now().
andytill/riak_kv