You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@couchdb.apache.org by JohnRodey <ti...@yahoo.com> on 2012/02/21 22:12:15 UTC

General question about views

I have some WebServices that act as a middle man between our client
applications and our backend repository(CouchDB).  I wanted to create and
infrastructure where users could enter search criteria to a web service post
and run a query on those fields and do so in a generic way that isnt vendor
specific.  I would like my client to be able to do something similar to
"http://host:port/query?name="bob",birthdatestart="1980/07/04",birthdateend="1981/07/04",hieght="6'1""".

I basically want the ability to handle any type of query that a user throws
at me.  But as Im looking it seems like this isnt exactly how CouchDB was
built.  It seems like I would rather have a set of supported queries such as
"http://host:port/query=findByBirthdate?birthdatestart="1980/07/04",birthdateend="1981/07/04"". 
Is this true?  I believe that I could accomplish what I want through
temporary views, but I know these are not desired for production.

If I can somehow handle dynamic query parameters, is there a way to handle
which fields from the document to return to the user?

Thanks for any insight!

--
View this message in context: http://couchdb-development.1959287.n2.nabble.com/General-question-about-views-tp7306229p7306229.html
Sent from the CouchDB Development mailing list archive at Nabble.com.

Re: General question about views

Posted by JohnRodey <ti...@yahoo.com>.
Ryan, first off thanks a ton for your response!!!

So is it a true statement that with either option, elasticsearch or
couchdb-lucene, they both create their own index based on the database that
you provide and keep things in sync between the two?  So then basically if I
used couchdb-lucene, from my java code could I execute my query as if it
were just a plain lucene client, with needing to even know the CouchDB is in
the mix?

Are there any known issues with running these on a mobile platform?

Also do you have a link to the users forum?  I will start posting my
questions there.

Thanks!!!

--
View this message in context: http://couchdb-development.1959287.n2.nabble.com/General-question-about-views-tp7306229p7306685.html
Sent from the CouchDB Development mailing list archive at Nabble.com.

Re: General question about views

Posted by Ryan Ramage <ry...@gmail.com>.
John,

These question are typically handled in the users forum.

But otherwise for generic queries you can use
https://github.com/rnewson/couchdb-lucene.

or elasticsearch
http://www.elasticsearch.org/guide/reference/river/couchdb.html

On Tue, Feb 21, 2012 at 2:12 PM, JohnRodey <ti...@yahoo.com> wrote:
> I have some WebServices that act as a middle man between our client
> applications and our backend repository(CouchDB).  I wanted to create and
> infrastructure where users could enter search criteria to a web service post
> and run a query on those fields and do so in a generic way that isnt vendor
> specific.  I would like my client to be able to do something similar to
> "http://host:port/query?name="bob",birthdatestart="1980/07/04",birthdateend="1981/07/04",hieght="6'1""".
>
> I basically want the ability to handle any type of query that a user throws
> at me.  But as Im looking it seems like this isnt exactly how CouchDB was
> built.  It seems like I would rather have a set of supported queries such as
> "http://host:port/query=findByBirthdate?birthdatestart="1980/07/04",birthdateend="1981/07/04"".
> Is this true?  I believe that I could accomplish what I want through
> temporary views, but I know these are not desired for production.
>
> If I can somehow handle dynamic query parameters, is there a way to handle
> which fields from the document to return to the user?
>
> Thanks for any insight!
>
> --
> View this message in context: http://couchdb-development.1959287.n2.nabble.com/General-question-about-views-tp7306229p7306229.html
> Sent from the CouchDB Development mailing list archive at Nabble.com.