[
https://issues.apache.org/jira/browse/COUCHDB-599?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Karel Minařík updated COUCHDB-599:
----------------------------------
Description:
In a _list function defined like this:
function (head, req) {
return 'Total: ' + head.total_rows;
}
the `head.total_rows` is undefined.
I have created a test case for the issue in this patch (against Git repo at
github.com/apache/couchdb):
-->
http://gist.github.com/255972#file_couchdb_head_total_rows_in_list__fail.diff
See the map/reduce and list function definition in the gist, also the full db
dump is included.
This fails for me on CouchDB 0.10.0 and 0.11.0b77473d79-git.
There are tests for `head.total_rows` commented out in the test cases
(list_views.js, see
http://github.com/apache/couchdb/blob/trunk/share/www/script/test/list_views.js#L65-68
and
http://github.com/apache/couchdb/blob/trunk/share/www/script/test/list_views.js#L265)
was:
In a _list function defined like this:
function (head, req) {
return 'Total: ' + head.total_rows;
}
the `head.total_rows` is undefined.
I have created a test case for the issue in this patch (against Git repo at
github.com/apache/couchdb):
-->
http://gist.github.com/255972#file_couchdb_head_total_rows_in_list__fail.diff
See the map/reduce and list function definition in the gist, also the full db
dump is included.
This fails fo me on CouchDB 0.10.0 and 0.11.0b77473d79-git.
There are tests for `head.total_rows` commented out in In the test cases
(list_views.js, see
http://github.com/apache/couchdb/blob/trunk/share/www/script/test/list_views.js#L65-68
and
http://github.com/apache/couchdb/blob/trunk/share/www/script/test/list_views.js#L265)
> `head.total_rows` returns empty in a _list function
> ---------------------------------------------------
>
> Key: COUCHDB-599
> URL: https://issues.apache.org/jira/browse/COUCHDB-599
> Project: CouchDB
> Issue Type: Bug
> Components: Database Core, Test Suite
> Affects Versions: 0.10, 0.11
> Environment: Mac OS X 10.5.8, Mac Book Air, CouchDB 0.10.0 (mac
> ports) and trunk
> Reporter: Karel Minařík
>
> In a _list function defined like this:
> function (head, req) {
> return 'Total: ' + head.total_rows;
> }
> the `head.total_rows` is undefined.
> I have created a test case for the issue in this patch (against Git repo at
> github.com/apache/couchdb):
> -->
> http://gist.github.com/255972#file_couchdb_head_total_rows_in_list__fail.diff
> See the map/reduce and list function definition in the gist, also the full db
> dump is included.
> This fails for me on CouchDB 0.10.0 and 0.11.0b77473d79-git.
> There are tests for `head.total_rows` commented out in the test cases
> (list_views.js, see
> http://github.com/apache/couchdb/blob/trunk/share/www/script/test/list_views.js#L65-68
> and
> http://github.com/apache/couchdb/blob/trunk/share/www/script/test/list_views.js#L265)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.