You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by hassancrowdc <ha...@gmail.com> on 2013/01/28 21:20:37 UTC
Modify result json file
Hi,
I want to change the name in the result json file from solr. Like i want
numFound to be be totalNumRecords etc. Any hint how i can do that?
--
View this message in context: http://lucene.472066.n3.nabble.com/Modify-result-json-file-tp4036853.html
Sent from the Solr - User mailing list archive at Nabble.com.
Re: Modify result json file
Posted by hassancrowdc <ha...@gmail.com>.
ok
--
View this message in context: http://lucene.472066.n3.nabble.com/Modify-result-json-file-tp4036853p4036868.html
Sent from the Solr - User mailing list archive at Nabble.com.
Re: Modify result json file
Posted by Gora Mohanty <go...@mimirtech.com>.
On 29 January 2013 02:41, hassancrowdc <ha...@gmail.com> wrote:
> i want smething like
> {current page:#
> totalNumRecords:#
> records:[]
> }
> because everything else in my website fllow this format.
> instead of:
> {response
> {numFound:
> start:
> docs:[]
> }
> }
> before someone responded me to skip the starting code(i m not sure how i can
> do that)
> Basically i understand solr and everything. Now i am trying to
> include(integrate) it with my website. I have search field and everything
> setup on my site.
It is difficult to understand why many of your questions seem
to have to do with adapting Solr to the very specific needs
of your web front-end. Solr is designed to be a search engine,
and not a CMS, nor another tool that it seems that you would
like it to be. In most cases that you have asked about, it
seems almost trivial to have a layer that parses the Solr
response into something that fits your needs, and depending
on your programming language of choice, there are various
libraries that ease such a task. Maybe you could focus on
developing such a layer rather than trying to fit a square peg
into a round hole.
Regards,
Gora
Re: Modify result json file
Posted by hassancrowdc <ha...@gmail.com>.
i want smething like
{current page:#
totalNumRecords:#
records:[]
}
because everything else in my website fllow this format.
instead of:
{response
{numFound:
start:
docs:[]
}
}
before someone responded me to skip the starting code(i m not sure how i can
do that)
Basically i understand solr and everything. Now i am trying to
include(integrate) it with my website. I have search field and everything
setup on my site.
--
View this message in context: http://lucene.472066.n3.nabble.com/Modify-result-json-file-tp4036853p4036863.html
Sent from the Solr - User mailing list archive at Nabble.com.
Re: Modify result json file
Posted by Gora Mohanty <go...@mimirtech.com>.
On 29 January 2013 01:50, hassancrowdc <ha...@gmail.com> wrote:
> Hi,
> I want to change the name in the result json file from solr. Like i want
> numFound to be be totalNumRecords etc. Any hint how i can do that?
This requirement seems a little strange: Could you
explain why you would want this?
Along the lines of responses from other people to
your earlier queries, the best way to achieve something
like this might be to use XSLT with the Solr XML
response. However, I would still re-examine why you
require this.
Regards,
Gora