You can't mix a bare field and a function in the same SELECT clause. The
system doesn't know how to return one result per GROUP BY interval for the
function but N results per interval for the bare field.

You are already grouping by the tag, "somecolumn", so it will be part of
the return and selecting it is redundant. If you actually meant to have a
different column in the select clause, then if it is a tag, add it to the
GROUP BY clause. If it is a field, use the FIRST, LAST or other selector
functions to return a single version of the field, or use an aggregator
function if it is numeric.

On Mon, Aug 1, 2016 at 6:49 AM, <[email protected]> wrote:

> Hi!
>
> I'm having a little trouble with a query in InfluxDB.  I'm trying to do a
> count function, but while grouping by a certain column, like this:
>
> select count(StatusCode)  , somecolumn  from mytable where time > now() -
> 10h group by  time(10m) , somecolumn order by time asc
>
> I get this error:
> error parsing query: mixing aggregate and non-aggregate queries is not
> supported
>
> It seems this worked in old versions of InfluxDB.  I am currently on
> version 0.11.  I can consider upgrading, but can't right away.
>
> Anyone have any ideas that can help me?
>
> Thanks!
>
> -J
>
> --
> 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/e99fef4c-4e03-4045-84a9-14d676d94d8e%40googlegroups.com
> .
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Sean Beckett
Director of Support and Professional Services
InfluxDB

-- 
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/CALGqCvPg3jWba_oiY6PrMudvjiJt%3Dh2Kb7-UrC0h9pvYGJfkhQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to