Usually the convention is you have some kind of 'type' attribute (so type
checking) on your documents or you check that all the fields you are
interested in exist (more of the duck approach) in your map function. So
perhaps your map function is something like:

function(doc){
    if (doc.type != 'line_item') return;

    var value = {



    emit([doc.l_shipdate, doc.l_returnflag, doc.l_linestate], {
}

On Mon, May 16, 2011 at 11:06 AM, Mauro Fagnoni <[email protected]>wrote:

> Stefan I'm trying to convert this sql query in an identical to the document
> I created in couchdb. Unfortunately, it is the first time using this
> database and would like to understand how to translate the query using only
> the wiki because I have not figured out how to do a lot
>
> 2011/5/16 Stefan Matheis <[email protected]>
>
> > i think a short example would be really helpful .. especially related
> > to your data-structure .. and the expected behaviour. do you already
> > have an reduce function, but it does not work like you'd have it to?
> >
>
>
>
> --
> -----------------------------------------------
> [-------WHOAMI------] Mauro Fagnoni
> [----------ICQ#---------] 279572903
> [--------MSNID--------] [email protected]
> [--YAHOOMSNID--] [email protected]
> [--GOOGLETALK--] [email protected]
> [-GOOGLEWAVE-] [email protected]
> [------JABBER-------] [email protected]
> [------SKYPE--------] mauro.fagnoni
> [-----LinuxUser#----] 346345
> [----------Blog---------] http://kingmauro.wordpress.com
> -----------------------------------------------
>



-- 
“The limits of language are the limits of one's world. “ -Ludwig von
Wittgenstein

Reply via email to