On Mon, Feb 2, 2015 at 11:45 AM, Mike Marino wrote:
> > Hi,
> >
> > why do you say it is a 'mistake' to emit doc from a view?
> > I do have views that get some param and return the resulting doc(s).
> > E.g.:
> >
> > |||"|map|":|"function(doc) {if(doc.startDate && !doc.disabled)
> > {emit(doc.sta
Or something similar...
>>>
>>> By the way, what is id_str? If you want to use the doc when
>>> requesting the
>>> view, it is better to request the document directly with
>>> ?include_docs=true, saving you a roundtrip to the server.
>>>
>>>
>>> On February 1, 2015, Ayhan Kesenci >> <mailto:a.kesenc...@googlemail.com>> wrote:
>>>
>>> Why it is not possible to create a view like this
>>>
>>> function(doc) {
>>> emit(doc.user.friends_count,doc.user.followers_count,doc.id_str);
>>> }
>>>
>>>
>>> ??
>>>
>>>
>>>
>
request the document directly with
?include_docs=true, saving you a roundtrip to the server.
On February 1, 2015, Ayhan Kesenci mailto:a.kesenc...@googlemail.com>> wrote:
Why it is not possible to create a view like this
function(doc) {
emit(doc.user.friends_count,doc.user.followers_count,doc.id_str);
}
??
ers_count], doc.id_str);
> >
> > Or something similar...
> >
> > By the way, what is id_str? If you want to use the doc when requesting the
> > view, it is better to request the document directly with
> > ?include_docs=true, saving you a roundt
imilar...
>
> By the way, what is id_str? If you want to use the doc when requesting the
> view, it is better to request the document directly with
> ?include_docs=true, saving you a roundtrip to the server.
>
>
> On February 1, 2015, Ayhan Kesenci wrote:
>
> Why it i
ser.followers_count], doc.id_str);
> >
> > Or something similar...
> >
> > By the way, what is id_str? If you want to use the doc when requesting the
> > view, it is better to request the document directly with
> > ?include_docs=true, saving you a roundtrip to the server.
p to the server.
>
>
> On February 1, 2015, Ayhan Kesenci wrote:
>
> Why it is not possible to create a view like this
>
> function(doc) {
> emit(doc.user.friends_count,doc.user.followers_count,doc.id_str);
> }
>
>
> ??
>
>
want to use the doc when requesting the
view, it is better to request the document directly with ?include_docs=true,
saving you a roundtrip to the server.
On February 1, 2015, Ayhan Kesenci wrote:
> Why it is not possible to create a view like this
>
> function(doc)
Why it is not possible to create a view like this
function(doc) {
emit(doc.user.friends_count,doc.user.followers_count,doc.id_str);
}
??