incubator-couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Oleg Krevosheev <o...@imcmilk.com.ua>
Subject Re: Native List Functions with CouchDB
Date Tue, 08 Feb 2011 07:19:38 GMT
Here's how I did.
{
     "_id": "_design / test",
     "_rev": "1931-98f79c92675e9541e448a62377dcc067 ",
     "language": "erlang",
     "views": {
         "vtest": {
             "map": "fun ({Doc}) -> \ n Key = proplists: get_value (<<\" 
key \ ">>, Doc, null), \ n Val = proplists: get_value (<<\" val \ ">>, 
Doc, null), \ n Emit (Key, Val) \ n end."
         }
     }
     "lists": {
         "ltest": "fun (Head, {Req}) -> Send (<<\" Test \ ">>) end."
     }
}
View works fine. Makes a request 
http://192.168.2.47:5984/proxy_02_2011/_design/test/_list/ltest/vtest 
nothing shows up

Mime
View raw message