couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robert Newson (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (COUCHDB-1117) Querying view with group parameter after group_level parameter is ignoring group_level parameter
Date Sat, 02 Apr 2011 14:38:05 GMT

    [ https://issues.apache.org/jira/browse/COUCHDB-1117?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13015033#comment-13015033
] 

Robert Newson commented on COUCHDB-1117:
----------------------------------------

group=true is mapped to {group_level, exact}. As we parse view arguments, we set group_level
to exact, and then to 3, or vice versa, depending on the order the user passed.

For cases like ?group_level=2&group_level=3, we'll use 3, but I think we should throw
an error instead.

For cases like ?group_level=2&group=true, I'd like to select 2, but that implies that
?group_level=exact&group_level=3 should select 3, which contradicts the previous error
condition.

Final option is to ignore this, if you set the same thing twice, with different values, the
behavior is undetermined. The reason I care about this case is that it's not obvious that
group=true is the same as group_level=exact.



> Querying view with group parameter after group_level parameter is ignoring group_level
parameter
> ------------------------------------------------------------------------------------------------
>
>                 Key: COUCHDB-1117
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-1117
>             Project: CouchDB
>          Issue Type: Bug
>          Components: HTTP Interface
>    Affects Versions: 1.1
>         Environment: {"couchdb":"Welcome","version":"1.1.0a771dd47-git"}
>            Reporter: Sameer Babu KK
>
> Query with 
> http://localhost:5984/t24-pmdata/_design/pm/_view/report?startkey=[3,%22temperature%22,2011,2,1]&endkey=[3,%22temperature%22,2011,2,29]&group_level=3&group=true
> returns different results than
> http://localhost:5984/t24-pmdata/_design/pm/_view/report?startkey=[3,%22temperature%22,2011,2,1]&endkey=[3,%22temperature%22,2011,2,29]&group=true&group_level=3

> or just
> http://localhost:5984/t24-pmdata/_design/pm/_view/report?startkey=[3,%22temperature%22,2011,2,1]&endkey=[3,%22temperature%22,2011,2,29]&group_level=3


--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message