Re: Post filter cache question

2013-10-24 Thread Eric Grobler
Hi Chris

Thank you for your response.
I will try to migrate to Solr 4.4 first!

Best regards



On Thu, Oct 24, 2013 at 10:44 PM, Chris Hostetter
wrote:

>
> : Could it be a problem with my cache settings in solrconfig.xml (solr 3.1)
> : or is my query wrong?
>
> 3.1? ouch ... PostFilter wasn't even added until 3.4...
> https://wiki.apache.org/solr/CommonQueryParameters#Caching_of_filters
>
> ...so your spatial filter is definitely being applied to the entire index
> and then getting cached.
>
> . . .
>
> Below is what i wrote before i saw that 3.4 comment at the end of your
> email...
>
> : If I run the same query but add a spatial filter with cost:
> : q=*:*
> : fl=adr_geopoint,adr_city,filterflags
> : *fq=(filterflags:TopList) *
> : pt=49.594,8.468
> : sfield=adr_geopoint
> : fq={!bbox d=30}
> : fq={!frange l=15 u=30 *cache=false *cost=200}geodist()
> :
> : It takes over 3 seconds even though it should only scan around 3000
> : documents from the first cached filter?
>
> You've also added a "bbox" filter, which will be computed against the
> entire index and cached.
>
> I'm not sure whta FieldType you are using, and i don't know a lot of the
> detials about hte spatial queries -- but things you should look into...
>
> 1) does the bbox gain you anything if you are already doing the geodist
> filter as a post filter?  (my hunch would be that the only point of a bbox
> fq is if you are *scoring* documents by distance and you want to ignore
> things beyond a set distance)
>
> 2) does {!bbox} support PostFilter on your FieldType? does
> adding "cache=false cost=150" to the bbox filter improve things?
>
>
>
> -Hoss
>


Post filter cache question

2013-10-24 Thread Eric Grobler
Hi

If I run this query it is very fast (<10 ms) because it uses a "TopList"
filter:
q=*:*
fl=adr_geopoint,adr_city,filterflags
*fq=(filterflags:TopList) *
and the number of relevant documents are 3000 out of 7 million.

If I run the same query but add a spatial filter with cost:
q=*:*
fl=adr_geopoint,adr_city,filterflags
*fq=(filterflags:TopList) *
pt=49.594,8.468
sfield=adr_geopoint
fq={!bbox d=30}
fq={!frange l=15 u=30 *cache=false *cost=200}geodist()

It takes over 3 seconds even though it should only scan around 3000
documents from the first cached filter?
Could it be a problem with my cache settings in solrconfig.xml (solr 3.1)
or is my query wrong?

Thanks & regards
Ericz


Re: Spatial Circle Search

2013-10-22 Thread Eric Grobler
Bill Bell suggested using frange and here is a stackoverflow example:


http://stackoverflow.com/questions/10867113/solr-distance-filtering
pt=45.15,-93.85&sfield=store&fq={!frange l=5 u=10 cache=false
cost=100}geodist()&fq={!bbox d=10}



On Tue, Oct 22, 2013 at 7:43 PM, Eric Grobler wrote:

> Hi Solr experts,
>
> fq={!geofilt pt=45.15,-93.85 sfield=store d=5} will return docs with 5 km
> (the gray area)
>
> I want to search in a circle around my location but only between 5 and 10
> km, the blue area.
>
> Something like:
> fq={!geofilt pt=45.15,-93.85 sfield=store *d=[10 TO 100]*}
>
> [image: Inline image 2]
>
> Is that possible in Solr?
>
> Thanks & regards
> Ericz
>


Re: Spatial Distance Range

2013-10-22 Thread Eric Grobler
Hi Bill,

I found what you were refering too :-)
http://stackoverflow.com/questions/10867113/solr-distance-filtering

Thanks!



On Tue, Oct 22, 2013 at 3:20 PM, Bill Bell  wrote:

> Yes frange works
>
> Bill Bell
> Sent from mobile
>
>
> > On Oct 22, 2013, at 8:17 AM, Eric Grobler 
> wrote:
> >
> > Hi Everyone,
> >
> > Normally one would search for documents where the location is within a
> > specified distance, for example widthin 5 km:
> > fq={!geofilt pt=45.15,-93.85 sfield=store
> > d=5}<
> http://localhost:8983/solr/select?wt=json&indent=true&fl=name,store&q=*:*&fq=%7B!geofilt%20pt=45.15,-93.85%20sfield=store%20d=5%7D
> >
> >
> > It there a way to specify a range between 10 and 20 km?
> > Something like:
> > fq={!geofilt pt=45.15,-93.85 sfield=store distancefrom=10
> > distanceupto=20}<
> http://localhost:8983/solr/select?wt=json&indent=true&fl=name,store&q=*:*&fq=%7B!geofilt%20pt=45.15,-93.85%20sfield=store%20d=5%7D
> >
> >
> > Thanks
> > Ericz
>


Re: Spatial Distance Range

2013-10-22 Thread Eric Grobler
This question was badly phrased.
I asked it again under the heading "Spatial Circle Search"



On Tue, Oct 22, 2013 at 3:17 PM, Eric Grobler wrote:

> Hi Everyone,
>
> Normally one would search for documents where the location is within a
> specified distance, for example widthin 5 km:
> fq={!geofilt pt=45.15,-93.85 sfield=store 
> d=5}<http://localhost:8983/solr/select?wt=json&indent=true&fl=name,store&q=*:*&fq=%7B!geofilt%20pt=45.15,-93.85%20sfield=store%20d=5%7D>
>
> It there a way to specify a range between 10 and 20 km?
> Something like:
> fq={!geofilt pt=45.15,-93.85 sfield=store distancefrom=10 
> distanceupto=20}<http://localhost:8983/solr/select?wt=json&indent=true&fl=name,store&q=*:*&fq=%7B!geofilt%20pt=45.15,-93.85%20sfield=store%20d=5%7D>
>
> Thanks
> Ericz
>


Spatial Circle Search

2013-10-22 Thread Eric Grobler
Hi Solr experts,

fq={!geofilt pt=45.15,-93.85 sfield=store d=5} will return docs with 5 km
(the gray area)

I want to search in a circle around my location but only between 5 and 10
km, the blue area.

Something like:
fq={!geofilt pt=45.15,-93.85 sfield=store *d=[10 TO 100]*}

[image: Inline image 2]

Is that possible in Solr?

Thanks & regards
Ericz


Re: Spatial Distance Range

2013-10-22 Thread Eric Grobler
Hi Everyone,

To explain this better,
fq={!geofilt pt=45.15,-93.85 sfield=store d=5} will search the gray area.
I want to search in a circle around my location but between 5 and 10 km,
the blue area.


[image: Inline image 1]


Regards
Ericz


On Tue, Oct 22, 2013 at 3:17 PM, Eric Grobler wrote:

> Hi Everyone,
>
> Normally one would search for documents where the location is within a
> specified distance, for example widthin 5 km:
> fq={!geofilt pt=45.15,-93.85 sfield=store 
> d=5}<http://localhost:8983/solr/select?wt=json&indent=true&fl=name,store&q=*:*&fq=%7B!geofilt%20pt=45.15,-93.85%20sfield=store%20d=5%7D>
>
> It there a way to specify a range between 10 and 20 km?
> Something like:
> fq={!geofilt pt=45.15,-93.85 sfield=store distancefrom=10 
> distanceupto=20}<http://localhost:8983/solr/select?wt=json&indent=true&fl=name,store&q=*:*&fq=%7B!geofilt%20pt=45.15,-93.85%20sfield=store%20d=5%7D>
>
> Thanks
> Ericz
>


Re: Spatial Distance Range

2013-10-22 Thread Eric Grobler
Hi Bill,

> Yes frange works
Do you mean range specifying kilometers?

Regards
Eric


On Tue, Oct 22, 2013 at 3:20 PM, Bill Bell  wrote:

> Yes frange works
>
> Bill Bell
> Sent from mobile
>
>
> > On Oct 22, 2013, at 8:17 AM, Eric Grobler 
> wrote:
> >
> > Hi Everyone,
> >
> > Normally one would search for documents where the location is within a
> > specified distance, for example widthin 5 km:
> > fq={!geofilt pt=45.15,-93.85 sfield=store
> > d=5}<
> http://localhost:8983/solr/select?wt=json&indent=true&fl=name,store&q=*:*&fq=%7B!geofilt%20pt=45.15,-93.85%20sfield=store%20d=5%7D
> >
> >
> > It there a way to specify a range between 10 and 20 km?
> > Something like:
> > fq={!geofilt pt=45.15,-93.85 sfield=store distancefrom=10
> > distanceupto=20}<
> http://localhost:8983/solr/select?wt=json&indent=true&fl=name,store&q=*:*&fq=%7B!geofilt%20pt=45.15,-93.85%20sfield=store%20d=5%7D
> >
> >
> > Thanks
> > Ericz
>


Spatial Distance Range

2013-10-22 Thread Eric Grobler
Hi Everyone,

Normally one would search for documents where the location is within a
specified distance, for example widthin 5 km:
fq={!geofilt pt=45.15,-93.85 sfield=store
d=5}

It there a way to specify a range between 10 and 20 km?
Something like:
fq={!geofilt pt=45.15,-93.85 sfield=store distancefrom=10
distanceupto=20}

Thanks
Ericz


Re: Solr 4.3.0 geo search with multiple coordinates

2013-05-27 Thread Eric Grobler
I think I found the reason/bug
the type was wrong, it should be



On Tue, May 28, 2013 at 1:37 AM, Eric Grobler wrote:

> Hi Solr experts,
>
> I have a solr 4.3 schema
>  "solr.SpatialRecursivePrefixTreeFieldType" geo="true" distErrPct="0.025"
> maxDistErr="0.09" units="degrees" />
>
>   multiValued*="true" />
>
> and xml data
> 51.1164,6.9612
> 52.3473,9.77564
>
> If I run this query:
> fq={!geofilt pt=51.11,6.9 sfield=location_geo d=20}
> I get no result.
>
>
> But if I remove the second geo line and only have this geo coordinate it
> works:
> 51.1164,6.9612
>
> *Thus it seems that the multi valued index does not work *even though
> solr returns the doc values as:
>  51.1164,6.9612 52.3473,9.77564 str> 
>
>
> Is my schema wrongly configured?
>
> Thanks
> Ericz
>
>
>
>


Solr 4.3.0 geo search with multiple coordinates

2013-05-27 Thread Eric Grobler
Hi Solr experts,

I have a solr 4.3 schema




and xml data
51.1164,6.9612
52.3473,9.77564

If I run this query:
fq={!geofilt pt=51.11,6.9 sfield=location_geo d=20}
I get no result.


But if I remove the second geo line and only have this geo coordinate it
works:
51.1164,6.9612

*Thus it seems that the multi valued index does not work *even though solr
returns the doc values as:
 51.1164,6.9612 52.3473,9.77564 


Is my schema wrongly configured?

Thanks
Ericz


Re: Delete query puzzle

2012-10-28 Thread Eric Grobler
Hi Erick

> You're probably on your own here. I'd be surprised if  people were
willing to work on code of that vintage.
Yes, this is not a vintage wine!

I just hoped someone would say, "ah, we had this issue before and..." :-)

I think best is to just upgrade like you suggested.

Thanks for your time
Ericz


On Sun, Oct 28, 2012 at 6:34 PM, Erick Erickson wrote:

> Oh, 1.4.1. You're probably on your own here. I'd be surprised if
> people were willing to work on code of that vintage. Are
> you sure you can't upgrade at least to 3.6?
>
> Best
> Erick
>
> On Sun, Oct 28, 2012 at 12:43 PM, Eric Grobler
>  wrote:
> > Hi Erick,
> >
> > It is Solr 1.41 (a Drupal installation) running on Jetty.
> > How can one get a stack trace? (there is no exception/error)
> >
> > Could it be that solr does something like this?
> > start delete job
> >cannot find bogus id to delete
> >does some reindex or optimization anyway regardless which takes 80
> > seconds
> > end delete job
> >
> > Anyway, does it sound like Solr is just waiting 80 seconds for some
> > exclusive lock or is it actually doing something in a background
> thread?. I
> > do not know what kind of calls drupal is doing.
> >
> > Thanks & Regards
> > Ericz
> >
> >
> >
> >
> > On Sun, Oct 28, 2012 at 3:08 PM, Erick Erickson  >wrote:
> >
> >> That is very weird. What version of Solr are you using, and is there
> >> any way you could get a stack trace when this is happening?
> >>
> >> Best
> >> Erick
> >>
> >> On Sun, Oct 28, 2012 at 6:22 AM, Eric Grobler <
> impalah...@googlemail.com>
> >> wrote:
> >> > Hi
> >> >
> >> > I am a bit confused why the server sometimes takes 80 seconds to
> respond
> >> > when I specify an id to delete than does not even exist in the index.
> >> >
> >> > If I loop this query and send a bogus id to delete every minute.
> >> > 03:27:38   125 ms  bogusidthatdoesnotexist
> >> commit
> >> > 03:28:38   125 ms  bogusidthatdoesnotexist
> >> commit
> >> > 03:29:38 69125 ms  bogusidthatdoesnotexist
> >> commit
> >> > 03:30:38   124 ms  bogusidthatdoesnotexist
> >> commit
> >> > 03:31:38 84141 ms  bogusidthatdoesnotexist
> >> commit
> >> > 03:33:38   125 ms  bogusidthatdoesnotexist
> >> commit
> >> > 03:34:38   141 ms  bogusidthatdoesnotexist
> >> commit
> >> > 03:35:43 55476 ms  bogusidthatdoesnotexist
> >> commit
> >> > 03:36:38   141 ms  bogusidthatdoesnotexist
> >> commit
> >> > This was at 3am and the server only has about 200,000 documents and is
> >> not
> >> > busy, average query time is a constant < 5ms.
> >> >
> >> > If the server takes 80 seconds when it needs to update the index I
> would
> >> > understand it.
> >> > *But in this case the id does not exists, so the server should just
> >> return
> >> > immediately?*
> >> > I then must assume that the delete command must be in some low
> priority
> >> > queue and waits for some exclusive lock?
> >> > When I look at the stats it seems that it was only my loop that did
> >> > cumulative_deletesById every minute.
> >> >
> >> > What settings in the solrconfig.xml would effect this behaviour?
> >> >
> >> > Thank you & Regards
> >> > Ericz
> >>
>


Re: Delete query puzzle

2012-10-28 Thread Eric Grobler
Hi Erick,

It is Solr 1.41 (a Drupal installation) running on Jetty.
How can one get a stack trace? (there is no exception/error)

Could it be that solr does something like this?
start delete job
   cannot find bogus id to delete
   does some reindex or optimization anyway regardless which takes 80
seconds
end delete job

Anyway, does it sound like Solr is just waiting 80 seconds for some
exclusive lock or is it actually doing something in a background thread?. I
do not know what kind of calls drupal is doing.

Thanks & Regards
Ericz




On Sun, Oct 28, 2012 at 3:08 PM, Erick Erickson wrote:

> That is very weird. What version of Solr are you using, and is there
> any way you could get a stack trace when this is happening?
>
> Best
> Erick
>
> On Sun, Oct 28, 2012 at 6:22 AM, Eric Grobler 
> wrote:
> > Hi
> >
> > I am a bit confused why the server sometimes takes 80 seconds to respond
> > when I specify an id to delete than does not even exist in the index.
> >
> > If I loop this query and send a bogus id to delete every minute.
> > 03:27:38   125 ms  bogusidthatdoesnotexist
> commit
> > 03:28:38   125 ms  bogusidthatdoesnotexist
> commit
> > 03:29:38 69125 ms  bogusidthatdoesnotexist
> commit
> > 03:30:38   124 ms  bogusidthatdoesnotexist
> commit
> > 03:31:38 84141 ms  bogusidthatdoesnotexist
> commit
> > 03:33:38   125 ms  bogusidthatdoesnotexist
> commit
> > 03:34:38   141 ms  bogusidthatdoesnotexist
> commit
> > 03:35:43 55476 ms  bogusidthatdoesnotexist
> commit
> > 03:36:38   141 ms  bogusidthatdoesnotexist
> commit
> > This was at 3am and the server only has about 200,000 documents and is
> not
> > busy, average query time is a constant < 5ms.
> >
> > If the server takes 80 seconds when it needs to update the index I would
> > understand it.
> > *But in this case the id does not exists, so the server should just
> return
> > immediately?*
> > I then must assume that the delete command must be in some low priority
> > queue and waits for some exclusive lock?
> > When I look at the stats it seems that it was only my loop that did
> > cumulative_deletesById every minute.
> >
> > What settings in the solrconfig.xml would effect this behaviour?
> >
> > Thank you & Regards
> > Ericz
>


Delete query puzzle

2012-10-28 Thread Eric Grobler
Hi

I am a bit confused why the server sometimes takes 80 seconds to respond
when I specify an id to delete than does not even exist in the index.

If I loop this query and send a bogus id to delete every minute.
03:27:38   125 ms  bogusidthatdoesnotexist commit
03:28:38   125 ms  bogusidthatdoesnotexist commit
03:29:38 69125 ms  bogusidthatdoesnotexist commit
03:30:38   124 ms  bogusidthatdoesnotexist commit
03:31:38 84141 ms  bogusidthatdoesnotexist commit
03:33:38   125 ms  bogusidthatdoesnotexist commit
03:34:38   141 ms  bogusidthatdoesnotexist commit
03:35:43 55476 ms  bogusidthatdoesnotexist commit
03:36:38   141 ms  bogusidthatdoesnotexist commit
This was at 3am and the server only has about 200,000 documents and is not
busy, average query time is a constant < 5ms.

If the server takes 80 seconds when it needs to update the index I would
understand it.
*But in this case the id does not exists, so the server should just return
immediately?*
I then must assume that the delete command must be in some low priority
queue and waits for some exclusive lock?
When I look at the stats it seems that it was only my loop that did
cumulative_deletesById every minute.

What settings in the solrconfig.xml would effect this behaviour?

Thank you & Regards
Ericz


Re: Spatial4j

2012-04-23 Thread Eric Grobler
Thank you David,

it is fantastic what people like you do for the Solr community.


On Mon, Apr 23, 2012 at 8:08 PM, David Smiley (@MITRE.org) <
dsmi...@mitre.org> wrote:

> Yes, I definitely think so.  At a minimum, I expect there will at least be
> a
> patch or built jar file for you to get going by 1 June.
>
> -
>  Author:
> http://www.packtpub.com/apache-solr-3-enterprise-search-server/book
> --
> View this message in context:
> http://lucene.472066.n3.nabble.com/Spatial4j-tp3932748p3933368.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>


Re: Spatial4j

2012-04-23 Thread Eric Grobler
Hi David,

Thank you for the information.
I am glad to hear that is basically ready to be integrated into lucene.

Regarding your backlog, is it realistic to expect 3304 resolved before June?

Best Regards
Ericz

On Mon, Apr 23, 2012 at 4:38 PM, Smiley, David W.  wrote:

> Ericz,
>
> See this issue:  https://issues.apache.org/jira/browse/SOLR-3304
> It's just a TODO issue right now but when it's completed, you'll be able
> to do polygon spatial queries.  All the software is written to do it right
> now but the missing Solr piece is temporarily at Spatial4j.com.  If you
> were to try to use it, you would need to build it as of the same date that
> the Lucene spatial module was added, in LUCENE-3795.  Also, FYI to do
> polygons, you need a 3rd party jar, JTS.
>
> I'm working through a backlog of things to get to but will get to it.
>
> ~ David Smiley
>
> On Apr 23, 2012, at 11:09 AM, Eric Grobler wrote:
>
> > Hello Solr Community,
> >
> > We are interested in polygon spatial queries.
> > I believe that Spatial4j supports it.
> >
> > Is there a solr branch available that includes Spatial4j?
> > Will this be part of a furure solr release?
> >
> > Thank you.
> >
> > Best Regards
> > Ericz
>
>


Spatial4j

2012-04-23 Thread Eric Grobler
Hello Solr Community,

We are interested in polygon spatial queries.
I believe that Spatial4j supports it.

Is there a solr branch available that includes Spatial4j?
Will this be part of a furure solr release?

Thank you.

Best Regards
Ericz


Re: Spatial Search and faceting

2012-02-16 Thread Eric Grobler
Hi William,

Thanks for the feedback.

I will try the group query and see how the performance with 2 queries is.

Best Regards
Ericz

On Thu, Feb 16, 2012 at 4:06 AM, William Bell  wrote:

> One way to do it is to group by city and then sort=geodist() asc
>
> select?group=true&group.field=city&sort=geodist() desc&rows=10&fl=city
>
> It might require 2 calls to SOLR to get it the way you want.
>
> On Wed, Feb 15, 2012 at 5:51 PM, Eric Grobler 
> wrote:
> > Hi Solr community,
> >
> > I am doing a spatial search and then do a facet by city.
> > Is it possible to then sort the faceted cities by distance?
> >
> > We would like to display the hits per city, but sort them by distance.
> >
> > Thanks & Regards
> > Ericz
> >
> > q=iphone
> > fq={!bbox}
> > sfield=geopoint
> > pt=49.594857,8.468614
> > d=50
> > fl=id,description,city,geopoint
> >
> > facet=true
> > facet.field=city
> > f.city.facet.limit=10
> > f.city.facet.sort=count //geodist() asc
>
>
>
> --
> Bill Bell
> billnb...@gmail.com
> cell 720-256-8076
>


Spatial Search and faceting

2012-02-15 Thread Eric Grobler
Hi Solr community,

I am doing a spatial search and then do a facet by city.
Is it possible to then sort the faceted cities by distance?

We would like to display the hits per city, but sort them by distance.

Thanks & Regards
Ericz

q=iphone
fq={!bbox}
sfield=geopoint
pt=49.594857,8.468614
d=50
fl=id,description,city,geopoint

facet=true
facet.field=city
f.city.facet.limit=10
f.city.facet.sort=count //geodist() asc


Re: Function in facet.query like min,max

2012-01-17 Thread Eric Grobler
Hi Erick

Thanks for your feedback.
I will try it tomorrow - if it works it will be perfect for my needs.

Have a nice day
Ericz

On Tue, Jan 17, 2012 at 4:28 PM, Erick Erickson wrote:

> I don't believe that's the case, have you tried it? From the page
> I referenced:
>
> "The stats component returns simple statistics for indexed
> numeric fields within the DocSet."
>
> And running a very quick test on the example data, I get different
> results when I used *:* and name:maxtor.
>
> That said, I'm not all that familiar with the stats component so I
> could well be wrong.
>
> Best
> Erick
>
> On Tue, Jan 17, 2012 at 11:16 AM, Eric Grobler
>  wrote:
> > Yes, I have, but unfortunately it works on the whole index and not for a
> > particular query.
> >
> >
> > On Tue, Jan 17, 2012 at 3:37 PM, Erick Erickson  >wrote:
> >
> >> have you seen the Stats component? See:
> >> http://wiki.apache.org/solr/StatsComponent
> >>
> >> Best
> >> Erick
> >>
> >> On Tue, Jan 17, 2012 at 8:34 AM, Eric Grobler <
> impalah...@googlemail.com>
> >> wrote:
> >> > Hi Solr community,
> >> >
> >> > Is it possible to return the lowest, highest and average price of a
> >> search
> >> > result using facets?
> >> > I tried something like: facet.query={!max(price,0)}
> >> > Is it possible and what is the correct syntax?
> >> >
> >> > q=htc android
> >> > facet=true
> >> > facet.query=price:[* TO 10]
> >> > facet.query=price:[11 TO 100]
> >> > facet.query=price:[101 TO *]
> >> > ???  facet.query={!max(price,0)}
> >> >
> >> >
> >> > Thanks & Regards
> >> > Ericz
> >>
>


Re: Function in facet.query like min,max

2012-01-17 Thread Eric Grobler
Yes, I have, but unfortunately it works on the whole index and not for a
particular query.


On Tue, Jan 17, 2012 at 3:37 PM, Erick Erickson wrote:

> have you seen the Stats component? See:
> http://wiki.apache.org/solr/StatsComponent
>
> Best
> Erick
>
> On Tue, Jan 17, 2012 at 8:34 AM, Eric Grobler 
> wrote:
> > Hi Solr community,
> >
> > Is it possible to return the lowest, highest and average price of a
> search
> > result using facets?
> > I tried something like: facet.query={!max(price,0)}
> > Is it possible and what is the correct syntax?
> >
> > q=htc android
> > facet=true
> > facet.query=price:[* TO 10]
> > facet.query=price:[11 TO 100]
> > facet.query=price:[101 TO *]
> > ???  facet.query={!max(price,0)}
> >
> >
> > Thanks & Regards
> > Ericz
>


Function in facet.query like min,max

2012-01-17 Thread Eric Grobler
Hi Solr community,

Is it possible to return the lowest, highest and average price of a search
result using facets?
I tried something like: facet.query={!max(price,0)}
Is it possible and what is the correct syntax?

q=htc android
facet=true
facet.query=price:[* TO 10]
facet.query=price:[11 TO 100]
facet.query=price:[101 TO *]
???  facet.query={!max(price,0)}


Thanks & Regards
Ericz


Re: Document row in solr Result

2011-09-12 Thread Eric Grobler
Hi Pierre,

Great idea, that will speed things up!

Thank your very much.

Regards
Ericz


On Mon, Sep 12, 2011 at 10:19 AM, Pierre GOSSE wrote:

> Hi Eric,
>
> If you want a query informing one customer of its product row at any given
> time, the easiest way is to filter on submission date greater than this
> customer's and return the result count. If you have 500 products with an
> earlier submission date, your row number is 501.
>
> Hope this helps,
>
> Pierre
>
>
> -----Message d'origine-
> De : Eric Grobler [mailto:impalah...@googlemail.com]
> Envoyé : lundi 12 septembre 2011 11:00
> À : solr-user@lucene.apache.org
> Objet : Re: Document row in solr Result
>
> Hi Manish,
>
> Thank you for your time.
>
> For upselling reasons I want to inform the customer that:
> "your product is on the last page of the search result. However, click here
> to put your product back on the first page..."
>
>
> Here is an example:
> I have a phone with productid 635001 in the iphone category.
> When I sort this category by submissiondate this product will be near the
> end of the result (on row 9863 in this example).
> At the moment I have to scan nearly 1 rows in the client to determine
> the position of this product.
> Is there a more efficient way to find the position of a specific document
> in
> a resultset without returning the full result?
>
> q=category:iphone
> fl=productid
> sort=submissiondate desc
> rows=1
>
>  row productid submissiondate
>   1 6565692011-09-12 08:12
>   2 6564682011-09-12 08:03
>   3 6562012011-09-11 23:41
> ...
> 9863 6350012011-08-11 17:22
> ...
> 9922 6344232011-08-10 21:51
>
> Regards
> Ericz
>
> On Mon, Sep 12, 2011 at 9:38 AM, Manish Bafna  >wrote:
>
> > You might not be able to find the row index.
> > Can you post your query in detail. The kind of inputs and outputs you are
> > expecting.
> >
> > On Mon, Sep 12, 2011 at 2:01 PM, Eric Grobler  > >wrote:
> >
> > > Hi Manish,
> > >
> > > Thanks for your reply - but how will that return me the row index of
> the
> > > original query.
> > >
> > > Regards
> > > Ericz
> > >
> > > On Mon, Sep 12, 2011 at 9:24 AM, Manish Bafna <
> manish.bafna...@gmail.com
> > > >wrote:
> > >
> > > > fq -> filter query parameter searches within the results.
> > > >
> > > > On Mon, Sep 12, 2011 at 1:49 PM, Eric Grobler <
> > impalah...@googlemail.com
> > > > >wrote:
> > > >
> > > > > Hi Solr experts,
> > > > >
> > > > > If you have a site with products sorted by submission date, the
> > product
> > > > of
> > > > > a
> > > > > customer might be on page 1 on the first day, and then move down to
> > > page
> > > > x
> > > > > as other customers submit newer entries.
> > > > >
> > > > > To find the row of a product you can of course run the query and
> loop
> > > > > through the result until you find the specific productid like:
> > > > > q=category:myproducttype
> > > > > fl=productid
> > > > > sort=submissiondate desc
> > > > > rows=1
> > > > >
> > > > > But is there perhaps a more efficient way to do this? Maybe a
> special
> > > > > syntax
> > > > > to search within the result.
> > > > >
> > > > > Thanks
> > > > > Ericz
> > > > >
> > > >
> > >
> >
>


Re: Document row in solr Result

2011-09-12 Thread Eric Grobler
Hi Manish,

Thank you for your time.

For upselling reasons I want to inform the customer that:
"your product is on the last page of the search result. However, click here
to put your product back on the first page..."


Here is an example:
I have a phone with productid 635001 in the iphone category.
When I sort this category by submissiondate this product will be near the
end of the result (on row 9863 in this example).
At the moment I have to scan nearly 1 rows in the client to determine
the position of this product.
Is there a more efficient way to find the position of a specific document in
a resultset without returning the full result?

q=category:iphone
fl=productid
sort=submissiondate desc
rows=1

 row productid submissiondate
   1 6565692011-09-12 08:12
   2 6564682011-09-12 08:03
   3 6562012011-09-11 23:41
...
9863 6350012011-08-11 17:22
...
9922 6344232011-08-10 21:51

Regards
Ericz

On Mon, Sep 12, 2011 at 9:38 AM, Manish Bafna wrote:

> You might not be able to find the row index.
> Can you post your query in detail. The kind of inputs and outputs you are
> expecting.
>
> On Mon, Sep 12, 2011 at 2:01 PM, Eric Grobler  >wrote:
>
> > Hi Manish,
> >
> > Thanks for your reply - but how will that return me the row index of the
> > original query.
> >
> > Regards
> > Ericz
> >
> > On Mon, Sep 12, 2011 at 9:24 AM, Manish Bafna  > >wrote:
> >
> > > fq -> filter query parameter searches within the results.
> > >
> > > On Mon, Sep 12, 2011 at 1:49 PM, Eric Grobler <
> impalah...@googlemail.com
> > > >wrote:
> > >
> > > > Hi Solr experts,
> > > >
> > > > If you have a site with products sorted by submission date, the
> product
> > > of
> > > > a
> > > > customer might be on page 1 on the first day, and then move down to
> > page
> > > x
> > > > as other customers submit newer entries.
> > > >
> > > > To find the row of a product you can of course run the query and loop
> > > > through the result until you find the specific productid like:
> > > > q=category:myproducttype
> > > > fl=productid
> > > > sort=submissiondate desc
> > > > rows=1
> > > >
> > > > But is there perhaps a more efficient way to do this? Maybe a special
> > > > syntax
> > > > to search within the result.
> > > >
> > > > Thanks
> > > > Ericz
> > > >
> > >
> >
>


Re: Document row in solr Result

2011-09-12 Thread Eric Grobler
Hi Manish,

Thanks for your reply - but how will that return me the row index of the
original query.

Regards
Ericz

On Mon, Sep 12, 2011 at 9:24 AM, Manish Bafna wrote:

> fq -> filter query parameter searches within the results.
>
> On Mon, Sep 12, 2011 at 1:49 PM, Eric Grobler  >wrote:
>
> > Hi Solr experts,
> >
> > If you have a site with products sorted by submission date, the product
> of
> > a
> > customer might be on page 1 on the first day, and then move down to page
> x
> > as other customers submit newer entries.
> >
> > To find the row of a product you can of course run the query and loop
> > through the result until you find the specific productid like:
> > q=category:myproducttype
> > fl=productid
> > sort=submissiondate desc
> > rows=1
> >
> > But is there perhaps a more efficient way to do this? Maybe a special
> > syntax
> > to search within the result.
> >
> > Thanks
> > Ericz
> >
>


Document row in solr Result

2011-09-12 Thread Eric Grobler
Hi Solr experts,

If you have a site with products sorted by submission date, the product of a
customer might be on page 1 on the first day, and then move down to page x
as other customers submit newer entries.

To find the row of a product you can of course run the query and loop
through the result until you find the specific productid like:
q=category:myproducttype
fl=productid
sort=submissiondate desc
rows=1

But is there perhaps a more efficient way to do this? Maybe a special syntax
to search within the result.

Thanks
Ericz


Re: Ebay Kleinanzeigen and Auto Suggest

2011-04-27 Thread Eric Grobler
Hi Otis,

The new Solr 3.1 Suggester also does not support filter queries.

Is anyone using shingles with faceting on large data?

Regards
Ericz

On Tue, Apr 26, 2011 at 10:06 PM, Otis Gospodnetic <
otis_gospodne...@yahoo.com> wrote:

> Hi Eric,
>
> Before using the terms component, allow me to point out:
>
> * http://sematext.com/products/autocomplete/index.html (used on
> http://search-lucene.com/ for example)
>
> * http://wiki.apache.org/solr/Suggester
>
>
> Otis
> 
> Sematext :: http://sematext.com/ :: Solr - Lucene - Nutch
> Lucene ecosystem search :: http://search-lucene.com/
>
>
>
> - Original Message 
> > From: Eric Grobler 
> > To: solr-user@lucene.apache.org
> > Sent: Tue, April 26, 2011 1:11:11 PM
> > Subject: Ebay Kleinanzeigen and Auto Suggest
> >
> > Hi
> >
> > Someone told me that ebay is using solr.
> > I was looking at their  Auto Suggest implementation and I guess they are
> > using Shingles and the  TermsComponent.
> >
> > I managed to get a satisfactory implementation but I have  a problem with
> > category specific filtering.
> > Ebay suggestions are sensitive  to categories like Cars and Pets.
> >
> > As far as I understand it is not  possible to using filters with a term
> > query.
> > Unless one uses multiple  fields or special prefixes for the words to
> index I
> > cannot think how to  implement this.
> >
> > Is their perhaps a workaround for this  limitation?
> >
> > Best  Regards
> > EricZ
> >
> > ---
> >
> > I am have  a shingle type like:
> >  > positionIncrementGap="100">
> > 
> >
> > > maxShingleSize="4"  />
> >
> >
> > 
> >
> >
> >
> > and a query like
> >
> http://localhost:8983/solr/terms?q=*%3A*&terms.fl=suggest_text&terms.sort=count&terms.prefix=audi
> >i
> >
>


Re: Ebay Kleinanzeigen and Auto Suggest

2011-04-26 Thread Eric Grobler
Thanks for the links Otis,

I will have a look.

Regards
Ericz

On Tue, Apr 26, 2011 at 10:06 PM, Otis Gospodnetic <
otis_gospodne...@yahoo.com> wrote:

> Hi Eric,
>
> Before using the terms component, allow me to point out:
>
> * http://sematext.com/products/autocomplete/index.html (used on
> http://search-lucene.com/ for example)
>
> * http://wiki.apache.org/solr/Suggester
>
>
> Otis
> 
> Sematext :: http://sematext.com/ :: Solr - Lucene - Nutch
> Lucene ecosystem search :: http://search-lucene.com/
>
>
>
> - Original Message 
> > From: Eric Grobler 
> > To: solr-user@lucene.apache.org
> > Sent: Tue, April 26, 2011 1:11:11 PM
> > Subject: Ebay Kleinanzeigen and Auto Suggest
> >
> > Hi
> >
> > Someone told me that ebay is using solr.
> > I was looking at their  Auto Suggest implementation and I guess they are
> > using Shingles and the  TermsComponent.
> >
> > I managed to get a satisfactory implementation but I have  a problem with
> > category specific filtering.
> > Ebay suggestions are sensitive  to categories like Cars and Pets.
> >
> > As far as I understand it is not  possible to using filters with a term
> > query.
> > Unless one uses multiple  fields or special prefixes for the words to
> index I
> > cannot think how to  implement this.
> >
> > Is their perhaps a workaround for this  limitation?
> >
> > Best  Regards
> > EricZ
> >
> > ---
> >
> > I am have  a shingle type like:
> >  > positionIncrementGap="100">
> > 
> >
> > > maxShingleSize="4"  />
> >
> >
> > 
> >
> >
> >
> > and a query like
> >
> http://localhost:8983/solr/terms?q=*%3A*&terms.fl=suggest_text&terms.sort=count&terms.prefix=audi
> >i
> >
>


Ebay Kleinanzeigen and Auto Suggest

2011-04-26 Thread Eric Grobler
Hi

Someone told me that ebay is using solr.
I was looking at their Auto Suggest implementation and I guess they are
using Shingles and the TermsComponent.

I managed to get a satisfactory implementation but I have a problem with
category specific filtering.
Ebay suggestions are sensitive to categories like Cars and Pets.

As far as I understand it is not possible to using filters with a term
query.
Unless one uses multiple fields or special prefixes for the words to index I
cannot think how to implement this.

Is their perhaps a workaround for this limitation?

Best Regards
EricZ

---

I am have a shingle type like:


  
   
   
  




and a query like
http://localhost:8983/solr/terms?q=*%3A*&terms.fl=suggest_text&terms.sort=count&terms.prefix=audi


Re: Eclipse: Invalid character constant

2011-04-06 Thread Eric Grobler
Hi Stefan,

Thanks, my eclipse is now perfectly configured.
It makes it very easy for amateurs like me!

For other amateurs the steps are:
1. checkout the sources:
*svn checkout
https://svn.apache.org/repos/asf/lucene/dev/branches/lucene_solr_3_1/*
2. the root folder (lucene_solr_3_1 in this example) contains a special
build.xml to create project settings for either eclipse or IntelliJ
IDEA. (it is not the build.xml in the solr subfolder that compiles
tomcat/jetty)
   run:  *ant eclipse*
3. Create a new Eclipse Java project, we need to specify an external folder.
GALILEO: "Create project from existing source"
HELIOS: Unclick "Use Default Location"
*Select the root svn folder *(lucene_solr_3_1)
Click finish and you should have solr configured in eclipse!

Regards
Ericz

On Tue, Apr 5, 2011 at 11:34 PM, Stefan Matheis <
matheis.ste...@googlemail.com> wrote:

> Eric,
>
> have a look at Line #67 in build.xml :)
> 
>
> Regards
> Stefan
>
> Am 06.04.2011 00:28, schrieb Eric Grobler:
>
>  Hi Robert,
>>
>> Thanks for the fast response!
>>
>> I used
>> https://svn.apache.org/repos/asf/lucene/dev/branches/lucene_solr_3_1/
>> but did not find 'ant eclipse'.
>>
>> However setting my projects Resouce encoding to UTF-8 worked.
>>
>> Thanks for your help and have a nice day :-)
>>
>> Regards
>> Ericz
>>
>> On Tue, Apr 5, 2011 at 11:14 PM, Robert Muir  wrote:
>>
>>  in eclipse you need to set your project's character encoding to UTF-8.
>>>
>>> if you are checking out the source code from svn, you can run 'ant
>>> eclipse'
>>> from the top level, and then hit refresh on your project. it will set
>>> your
>>> encoding and your classpath up.
>>>
>>> On Tue, Apr 5, 2011 at 6:10 PM, Eric Grobler>>
>>>> wrote:
>>>>
>>>
>>>  Hi Everyone,
>>>>
>>>> Some language specific classes like GermanLightStemmer has invalid
>>>> character
>>>> compiler errors for code like:
>>>>  switch(s[i]) {
>>>>case 'ä':
>>>>case 'Ã ':
>>>>case 'á':
>>>> in Eclipse with JDK 1.6
>>>>
>>>> How do I get rid of these errors?
>>>> Thanks&  Regards
>>>>
>>>> Ericz
>>>>
>>>>
>>>
>>


Re: Eclipse: Invalid character constant

2011-04-05 Thread Eric Grobler
Hi Stefan,

Thanks for the information.
I used "Checkout Projects from SVN" inside eclipse which does not have the
root build.xml file.

What does this "eclipse" build actually do?

Thanks & Regards
Eric

On Tue, Apr 5, 2011 at 11:34 PM, Stefan Matheis <
matheis.ste...@googlemail.com> wrote:

> Eric,
>
> have a look at Line #67 in build.xml :)
> 
>
> Regards
> Stefan
>
> Am 06.04.2011 00:28, schrieb Eric Grobler:
>
>  Hi Robert,
>>
>> Thanks for the fast response!
>>
>> I used
>> https://svn.apache.org/repos/asf/lucene/dev/branches/lucene_solr_3_1/
>> but did not find 'ant eclipse'.
>>
>> However setting my projects Resouce encoding to UTF-8 worked.
>>
>> Thanks for your help and have a nice day :-)
>>
>> Regards
>> Ericz
>>
>> On Tue, Apr 5, 2011 at 11:14 PM, Robert Muir  wrote:
>>
>>  in eclipse you need to set your project's character encoding to UTF-8.
>>>
>>> if you are checking out the source code from svn, you can run 'ant
>>> eclipse'
>>> from the top level, and then hit refresh on your project. it will set
>>> your
>>> encoding and your classpath up.
>>>
>>> On Tue, Apr 5, 2011 at 6:10 PM, Eric Grobler>>
>>>> wrote:
>>>>
>>>
>>>  Hi Everyone,
>>>>
>>>> Some language specific classes like GermanLightStemmer has invalid
>>>> character
>>>> compiler errors for code like:
>>>>  switch(s[i]) {
>>>>case 'ä':
>>>>case 'Ã ':
>>>>case 'á':
>>>> in Eclipse with JDK 1.6
>>>>
>>>> How do I get rid of these errors?
>>>> Thanks&  Regards
>>>>
>>>> Ericz
>>>>
>>>>
>>>
>>


Re: Eclipse: Invalid character constant

2011-04-05 Thread Eric Grobler
Hi Robert,

Thanks for the fast response!

I used
https://svn.apache.org/repos/asf/lucene/dev/branches/lucene_solr_3_1/
but did not find 'ant eclipse'.

However setting my projects Resouce encoding to UTF-8 worked.

Thanks for your help and have a nice day :-)

Regards
Ericz

On Tue, Apr 5, 2011 at 11:14 PM, Robert Muir  wrote:

> in eclipse you need to set your project's character encoding to UTF-8.
>
> if you are checking out the source code from svn, you can run 'ant eclipse'
> from the top level, and then hit refresh on your project. it will set your
> encoding and your classpath up.
>
> On Tue, Apr 5, 2011 at 6:10 PM, Eric Grobler  >wrote:
>
> > Hi Everyone,
> >
> > Some language specific classes like GermanLightStemmer has invalid
> > character
> > compiler errors for code like:
> >  switch(s[i]) {
> >case 'ä':
> >case 'Ã ':
> >case 'á':
> > in Eclipse with JDK 1.6
> >
> > How do I get rid of these errors?
> > Thanks & Regards
> >
> > Ericz
> >
>


Eclipse: Invalid character constant

2011-04-05 Thread Eric Grobler
Hi Everyone,

Some language specific classes like GermanLightStemmer has invalid character
compiler errors for code like:
  switch(s[i]) {
case 'ä':
case 'Ã ':
case 'á':
in Eclipse with JDK 1.6

How do I get rid of these errors?
Thanks & Regards

Ericz


Re: geodist and spacial search

2011-02-07 Thread Eric Grobler
Thanks Bill,

much simpler :-)



On Sat, Feb 5, 2011 at 3:56 AM, Bill Bell  wrote:

> Why not just:
>
> q=*:*
> fq={!bbox}
> sfield=store
> pt=49.45031,11.077721
> d=40
> fl=store
> sort=geodist() asc
>
>
> http://localhost:8983/solr/select?q=*:*&sfield=store&pt=49.45031,11.077721&;
> d=40&fq={!bbox}&sort=geodist%28%29%20asc
>
> That will sort, and filter up to 40km.
>
> No need for the
>
> fq={!func}geodist()
> sfield=store
> pt=49.45031,11.077721
>
>
> Bill
>
>
>
>
> On 2/4/11 4:30 AM, "Eric Grobler"  wrote:
>
> >Hi Grant,
> >
> >Thanks for the tip
> >This seems to work:
> >
> >q=*:*
> >fq={!func}geodist()
> >sfield=store
> >pt=49.45031,11.077721
> >
> >fq={!bbox}
> >sfield=store
> >pt=49.45031,11.077721
> >d=40
> >
> >fl=store
> >sort=geodist() asc
> >
> >
> >On Thu, Feb 3, 2011 at 7:46 PM, Grant Ingersoll 
> >wrote:
> >
> >> Use a filter query?  See the {!geofilt} stuff on the wiki page.  That
> >>gives
> >> you your filter to restrict down your result set, then you can sort by
> >>exact
> >> distance to get your sort of just those docs that make it through the
> >> filter.
> >>
> >>
> >> On Feb 3, 2011, at 10:24 AM, Eric Grobler wrote:
> >>
> >> > Hi Erick,
> >> >
> >> > Thanks I saw that example, but I am trying to sort by distance AND
> >> specify
> >> > the max distance in 1 query.
> >> >
> >> > The reason is:
> >> > running bbox on 2 million documents with a 20km distance takes only
> >> 200ms.
> >> > Sorting 2 million documents by distance takes over 1.5 seconds!
> >> >
> >> > So it will be much faster for solr to first filter the 20km documents
> >>and
> >> > then to sort them.
> >> >
> >> > Regards
> >> > Ericz
> >> >
> >> > On Thu, Feb 3, 2011 at 1:27 PM, Erick Erickson
> >> >> >wrote:
> >> >
> >> >> Further down that very page ...
> >> >>
> >> >> Here's an example of sorting by distance ascending:
> >> >>
> >> >>  -
> >> >>
> >> >>  ...&q=*:*&sfield=store&pt=45.15,-93.85&sort=geodist()
> >> >> asc<
> >> >>
> >>
> >>
> http://localhost:8983/solr/select?wt=json&indent=true&fl=name,store&q=*:*
> >>&sfield=store&pt=45.15,-93.85&sort=geodist()%20asc
> >> >>>
> >> >>
> >> >>
> >> >>
> >> >>
> >> >> The key is just the &sort=geodist(), I'm pretty sure that's
> >>independent
> >> of
> >> >> the bbox, but
> >> >> I could be wrong.
> >> >>
> >> >> Best
> >> >> Erick
> >> >>
> >> >> On Wed, Feb 2, 2011 at 11:18 AM, Eric Grobler <
> >> impalah...@googlemail.com
> >> >>> wrote:
> >> >>
> >> >>> Hi
> >> >>>
> >> >>> In http://wiki.apache.org/solr/SpatialSearch
> >> >>> there is an example of a bbox filter and a geodist function.
> >> >>>
> >> >>> Is it possible to do a bbox filter and sort by distance - combine
> >>the
> >> >> two?
> >> >>>
> >> >>> Thanks
> >> >>> Ericz
> >> >>>
> >> >>
> >>
> >> --
> >> Grant Ingersoll
> >> http://www.lucidimagination.com/
> >>
> >> Search the Lucene ecosystem docs using Solr/Lucene:
> >> http://www.lucidimagination.com/search
> >>
> >>
>
>
>


Re: geodist and spacial search

2011-02-04 Thread Eric Grobler
Hi Grant,

Thanks for the tip
This seems to work:

q=*:*
fq={!func}geodist()
sfield=store
pt=49.45031,11.077721

fq={!bbox}
sfield=store
pt=49.45031,11.077721
d=40

fl=store
sort=geodist() asc


On Thu, Feb 3, 2011 at 7:46 PM, Grant Ingersoll  wrote:

> Use a filter query?  See the {!geofilt} stuff on the wiki page.  That gives
> you your filter to restrict down your result set, then you can sort by exact
> distance to get your sort of just those docs that make it through the
> filter.
>
>
> On Feb 3, 2011, at 10:24 AM, Eric Grobler wrote:
>
> > Hi Erick,
> >
> > Thanks I saw that example, but I am trying to sort by distance AND
> specify
> > the max distance in 1 query.
> >
> > The reason is:
> > running bbox on 2 million documents with a 20km distance takes only
> 200ms.
> > Sorting 2 million documents by distance takes over 1.5 seconds!
> >
> > So it will be much faster for solr to first filter the 20km documents and
> > then to sort them.
> >
> > Regards
> > Ericz
> >
> > On Thu, Feb 3, 2011 at 1:27 PM, Erick Erickson  >wrote:
> >
> >> Further down that very page ...
> >>
> >> Here's an example of sorting by distance ascending:
> >>
> >>  -
> >>
> >>  ...&q=*:*&sfield=store&pt=45.15,-93.85&sort=geodist()
> >> asc<
> >>
> http://localhost:8983/solr/select?wt=json&indent=true&fl=name,store&q=*:*&sfield=store&pt=45.15,-93.85&sort=geodist()%20asc
> >>>
> >>
> >>
> >>
> >>
> >> The key is just the &sort=geodist(), I'm pretty sure that's independent
> of
> >> the bbox, but
> >> I could be wrong.
> >>
> >> Best
> >> Erick
> >>
> >> On Wed, Feb 2, 2011 at 11:18 AM, Eric Grobler <
> impalah...@googlemail.com
> >>> wrote:
> >>
> >>> Hi
> >>>
> >>> In http://wiki.apache.org/solr/SpatialSearch
> >>> there is an example of a bbox filter and a geodist function.
> >>>
> >>> Is it possible to do a bbox filter and sort by distance - combine the
> >> two?
> >>>
> >>> Thanks
> >>> Ericz
> >>>
> >>
>
> --
> Grant Ingersoll
> http://www.lucidimagination.com/
>
> Search the Lucene ecosystem docs using Solr/Lucene:
> http://www.lucidimagination.com/search
>
>


Re: geodist and spacial search

2011-02-03 Thread Eric Grobler
Hi Erick,

Thanks I saw that example, but I am trying to sort by distance AND specify
the max distance in 1 query.

The reason is:
running bbox on 2 million documents with a 20km distance takes only 200ms.
Sorting 2 million documents by distance takes over 1.5 seconds!

So it will be much faster for solr to first filter the 20km documents and
then to sort them.

Regards
Ericz

On Thu, Feb 3, 2011 at 1:27 PM, Erick Erickson wrote:

> Further down that very page ...
>
> Here's an example of sorting by distance ascending:
>
>   -
>
>   ...&q=*:*&sfield=store&pt=45.15,-93.85&sort=geodist()
> asc<
> http://localhost:8983/solr/select?wt=json&indent=true&fl=name,store&q=*:*&sfield=store&pt=45.15,-93.85&sort=geodist()%20asc
> >
>
>
>
>
> The key is just the &sort=geodist(), I'm pretty sure that's independent of
> the bbox, but
> I could be wrong.
>
> Best
> Erick
>
> On Wed, Feb 2, 2011 at 11:18 AM, Eric Grobler  >wrote:
>
> > Hi
> >
> > In http://wiki.apache.org/solr/SpatialSearch
> > there is an example of a bbox filter and a geodist function.
> >
> > Is it possible to do a bbox filter and sort by distance - combine the
> two?
> >
> > Thanks
> > Ericz
> >
>


Re: Solr and Eclipse

2011-02-02 Thread Eric Grobler
> I only use eclipse as a fancy text editor!
Eclipse will feed insulted :-)

I will just try to create hot keys to start/stop jetty manually.
Thanks for your feedback

Regards
Ericz


On Wed, Feb 2, 2011 at 4:26 PM, Robert Muir  wrote:

> On Wed, Feb 2, 2011 at 11:15 AM, Eric Grobler 
> wrote:
> >> I always use New...Other...SVN...Checkout Projects from SVN
> >
> > And how do run in eclipse jetty in the example folder?
> >
>
> you can always go to the commandline and use the usual techniques,
> e.g. ant run-example, or java -jar start.jar from the example
> folder... this is what i do, sorry I don't have a better suggestion, I
> only use eclipse as a fancy text editor!
>


geodist and spacial search

2011-02-02 Thread Eric Grobler
Hi

In http://wiki.apache.org/solr/SpatialSearch
there is an example of a bbox filter and a geodist function.

Is it possible to do a bbox filter and sort by distance - combine the two?

Thanks
Ericz


Re: Solr and Eclipse

2011-02-02 Thread Eric Grobler
> I always use New...Other...SVN...Checkout Projects from SVN

And how do run in eclipse jetty in the example folder?

Thanks for your help
Ericz


On Wed, Feb 2, 2011 at 12:43 PM, Robert Muir  wrote:

> On Tue, Feb 1, 2011 at 5:59 PM, Eric Grobler 
> wrote:
> > Hi
> >
> > I am a newbie and I am trying to run solr in eclipse.
> >
> > From this url
> > http://wiki.apache.org/solr/HowToContribute#Development_Environment_Tips
> > there is a subclipse example:
> >
> > I use Team -> Share Project and this url:
> >  http://svn.apache.org/repos/asf/lucene/dev/trunk
> >
> > but I get a "access forbidden for unknown reason error"
> >
> > I assume using readonly http I do not need credentials?
> >
> > Also, would it make more sense to rather checkout the project with
> > the command-line svn and in Eclipse use
> > "Create project from existing source"?
> >
>
> I always use New...Other...SVN...Checkout Projects from SVN
>


Re: Solr and Eclipse

2011-02-02 Thread Eric Grobler
> I always use New...Other...SVN...Checkout Projects from SVN

Thanks, that seemed to work perfectly :-)

On Wed, Feb 2, 2011 at 12:43 PM, Robert Muir  wrote:

> On Tue, Feb 1, 2011 at 5:59 PM, Eric Grobler 
> wrote:
> > Hi
> >
> > I am a newbie and I am trying to run solr in eclipse.
> >
> > From this url
> > http://wiki.apache.org/solr/HowToContribute#Development_Environment_Tips
> > there is a subclipse example:
> >
> > I use Team -> Share Project and this url:
> >  http://svn.apache.org/repos/asf/lucene/dev/trunk
> >
> > but I get a "access forbidden for unknown reason error"
> >
> > I assume using readonly http I do not need credentials?
> >
> > Also, would it make more sense to rather checkout the project with
> > the command-line svn and in Eclipse use
> > "Create project from existing source"?
> >
>
> I always use New...Other...SVN...Checkout Projects from SVN
>


Solr and Eclipse

2011-02-01 Thread Eric Grobler
Hi

I am a newbie and I am trying to run solr in eclipse.

>From this url
http://wiki.apache.org/solr/HowToContribute#Development_Environment_Tips
there is a subclipse example:

I use Team -> Share Project and this url:
  http://svn.apache.org/repos/asf/lucene/dev/trunk

but I get a "access forbidden for unknown reason error"

I assume using readonly http I do not need credentials?

Also, would it make more sense to rather checkout the project with
the command-line svn and in Eclipse use
"Create project from existing source"?


Thanks
Ericz


Facet same field with different preifx

2010-12-03 Thread Eric Grobler
Hi Everyone,

Can I facet the same field twice with a different prefix as per example
below?

facet.field=myfield
f.myfield.facet.prefix=*make*
f.myfield.facet.sort=count

facet.field=myfield
f.myfield.facet.prefix=*model*
f.myfield.facet.sort=count


Thanks and Regards
Ericz


Re: Auto Suggest

2010-09-01 Thread Eric Grobler
Thanks for your feedback Robert,

I will try that and see how Solr performs on my data - I think I will create
a field that contains only important key/product terms from the text.

Regards
Johan

On Wed, Sep 1, 2010 at 9:12 PM, Robert Petersen  wrote:

> We don't have that many, just a hundred thousand, and solr response
> times (since the index's docs are small and not complex) are logged as
> typically 1 ms if not 0 ms.  It's funny but sometimes it is so fast no
> milliseconds have elapsed.  Incredible if you ask me...  :)
>
> Once you get SOLR to consider the whole phrase as just one big term, the
> wildcard is very fast.
>
> -Original Message-
> From: Eric Grobler [mailto:impalah...@googlemail.com]
> Sent: Wednesday, September 01, 2010 12:35 PM
> To: solr-user@lucene.apache.org
> Subject: Re: Auto Suggest
>
> Hi Robert,
>
> Interesting approach, how many documents do you have in Solr?
> I have about 2 million and I just wonder if it might be a bit slow.
>
> Regards
> Johan
>
> On Wed, Sep 1, 2010 at 7:38 PM, Robert Petersen 
> wrote:
>
> > I do this by replacing the spaces with a '%' in a separate search
> field
> > which is not parsed nor tokenized and then you can wildcard across the
> > whole phrase like you want and the spaces don't mess you up.  Just
> store
> > the original phrase with spaces in a separate field for returning to
> the
> > front end for display.
> >
> > -Original Message-
> > From: Jazz Globe [mailto:jazzgl...@hotmail.com]
> > Sent: Wednesday, September 01, 2010 7:33 AM
> > To: solr-user@lucene.apache.org
> > Subject: Auto Suggest
> >
> >
> > Hallo
> >
> > How would one implement a multiple term auto-suggest feature in Solr
> > that is filter sensitive?
> > For example, a user enters :
> > "mp3"
> >  and solr might suggest:
> >  ->   "mp3 player"
> >  ->   "mp3 nano"
> >  ->   "mp3 sony"
> > and then the user starts the second word :
> > "mp3 n"
> > and that narrows it down to:
> >  -> "mp3 nano"
> >
> > I had a quick look at the Terms Component.
> > I suppose it just returns term totals for the entire index and cannot
> be
> > used with a filter or query?
> >
> > Thanks
> > Johan
> >
> >
> >
>


Re: Auto Suggest

2010-09-01 Thread Eric Grobler
Hi Robert,

Interesting approach, how many documents do you have in Solr?
I have about 2 million and I just wonder if it might be a bit slow.

Regards
Johan

On Wed, Sep 1, 2010 at 7:38 PM, Robert Petersen  wrote:

> I do this by replacing the spaces with a '%' in a separate search field
> which is not parsed nor tokenized and then you can wildcard across the
> whole phrase like you want and the spaces don't mess you up.  Just store
> the original phrase with spaces in a separate field for returning to the
> front end for display.
>
> -Original Message-
> From: Jazz Globe [mailto:jazzgl...@hotmail.com]
> Sent: Wednesday, September 01, 2010 7:33 AM
> To: solr-user@lucene.apache.org
> Subject: Auto Suggest
>
>
> Hallo
>
> How would one implement a multiple term auto-suggest feature in Solr
> that is filter sensitive?
> For example, a user enters :
> "mp3"
>  and solr might suggest:
>  ->   "mp3 player"
>  ->   "mp3 nano"
>  ->   "mp3 sony"
> and then the user starts the second word :
> "mp3 n"
> and that narrows it down to:
>  -> "mp3 nano"
>
> I had a quick look at the Terms Component.
> I suppose it just returns term totals for the entire index and cannot be
> used with a filter or query?
>
> Thanks
> Johan
>
>
>


Re: Filter Query question

2010-08-30 Thread Eric Grobler
Hi Grant,

Thanks for the explanation.

Regards
ericz

On Mon, Aug 30, 2010 at 3:22 PM, Grant Ingersoll wrote:

>
> On Aug 30, 2010, at 7:20 AM, Eric Grobler wrote:
>
> > Hi Solr Community
> >
> > If you use a filter like:
> >  q=*:*
> >  fq=make:Volkswagen
> >
> > and then the next query is:
> >  q=blue
> >  fq=make:Volkswagen
> >
> > will Solr use the filter cache before the main query, or only after a
> "blue"
> > subset?
>
> The first query will put the FQ into the cache and then it will be re-used
> on the second (and all subsequent) queries that use it.
>
> > In other words will this query make more sense?
> >  q=(blue) AND (make:Volkswagen)
> >
> > What are the do's and don'ts of Filter Queries and are there differences
> > between Solr versions?
>
> You should use FQs when you expect to have cache hits and can also afford
> the extra memory and won't get hit by garbage collection pauses when doing
> commits, etc.
>
>
> --
> Grant Ingersoll
> http://lucenerevolution.org Apache Lucene/Solr Conference, Boston Oct 7-8
>
>


Filter Query question

2010-08-30 Thread Eric Grobler
Hi Solr Community

If you use a filter like:
  q=*:*
  fq=make:Volkswagen

and then the next query is:
  q=blue
  fq=make:Volkswagen

will Solr use the filter cache before the main query, or only after a "blue"
subset?
In other words will this query make more sense?
  q=(blue) AND (make:Volkswagen)

What are the do's and don'ts of Filter Queries and are there differences
between Solr versions?

Thanks
Ericz


Re: Slow facet sorting - lex vs count

2010-08-26 Thread Eric Grobler
Hi Yonik,

Thanks for your help.

I will check the memory.

It might also be related to patch SOLR-792 tree faceting I installed.
I will remove it and try the same query tomorrow again.

Regards
Eric


On Wed, Aug 25, 2010 at 10:25 PM, Yonik Seeley
wrote:

> On Wed, Aug 25, 2010 at 7:22 AM, Eric Grobler 
> wrote:
> > Hi Solr experts,
> >
> > There is a huge difference doing facet sorting on lex vs count
> > The strange thing is that count sorting is fast when setting a small
> limit.
> > I realize I can do sorting in the client, but I am just curious why this
> is.
> >
> > FAST - 16ms
> > facet.field=city
> > f.city.facet.limit=5000
> > f.city.facet.sort=lex
> >
> > FAST - 20 ms
> > facet.field=city
> > f.city.facet.limit=50
> > f.city.facet.sort=count
> >
> > SLOW - over 1 second
> > facet.field=city
> > f.city.facet.limit=5000
> > f.city.facet.sort=count
>
> FYI, I just tried my own single-valued faceting test:
> 10M documents, query matches 1M docs, faceting on a field that has
> 100,000 unique values:
>
> facet.limit=100 -> 35ms
> facet.limit=5000 -> 44ms
> facet.limit=5 -> 100ms
>
> The times are reported via QTime (i.e. they do not include the time to
> write out the response to the client).
> Maybe you're running into memory issues because of the size of the
> BoundedTreeSet, response size, etc, and garbage collection is taking
> up a lot of time?
>
> -Yonik
> http://lucenerevolution.org  Lucene/Solr Conference, Boston Oct 7-8
>


Re: Slow facet sorting - lex vs count

2010-08-25 Thread Eric Grobler
Hi Yonik,

Thanks for the technical explanation.
I will in general try to use lex and sort by count in the client if there
are not too many rows.

Have a nice day.

Regards
ericz


On Wed, Aug 25, 2010 at 4:41 PM, Yonik Seeley wrote:

> On Wed, Aug 25, 2010 at 10:07 AM, Eric Grobler
>  wrote:
> > I use Solr 1.41
> > There are 14000 cities in the index.
> > The type is just a simple string:  > class="solr.StrField" sortMissingLast="true" omitNorms="true"/>
> > The facet method is fc.
> >
> > You are right I do not need 5000 cities, I was just surprised to see this
> > big difference, there are places where I do need to sort count and return
> > about 500 items.
> >
> > If Solr was also slow in locating the highest count city it would be less
> > surprising.
> > In other words, if I set the limit to 1, then solr returns Berlin as the
> > city with the highest count within 3ms which seems to indicate that the
> > facet is internally sorted by count.
> > However, the speed regresses linearly, 30ms for 10, 300ms for 1000 etc.
>
> The priority queue collecting values will be larger of course, but in
> this specific instance I bet most of  the time is being taken up in
> converting from term number to term value.  Here's a snippet of a
> comment from the implementation:
>  *   To further save memory, the terms (the actual string values) are
> not all stored in
>  *   memory, but a TermIndex is used to convert term numbers to term values
> only
>  *   for the terms needed after faceting has completed.  Only every
> 128th term value
>  *   is stored, along with it's corresponding term number, and this is
> used as an
>  *   index to find the closest term and iterate until the desired
> number is hit (very
>  *   much like Lucene's own internal term index).
>
> This is something that Lucene has improved in trunk, and that solr can
> make improvements to also.
> Besides optimizations, we could also implement options to store all
> values and eliminate the need to read the index to do the ord->string
> conversions.
>
> -Yonik
> http://lucenerevolution.org  Lucene/Solr Conference, Boston Oct 7-8
>
>
> > Regards
> > Eric
> >
> > On Wed, Aug 25, 2010 at 3:28 PM, Yonik Seeley <
> yo...@lucidimagination.com>
> > wrote:
> >>
> >> On Wed, Aug 25, 2010 at 7:22 AM, Eric Grobler <
> impalah...@googlemail.com>
> >> wrote:
> >> > There is a huge difference doing facet sorting on lex vs count
> >> > The strange thing is that count sorting is fast when setting a small
> >> > limit.
> >> > I realize I can do sorting in the client, but I am just curious why
> this
> >> > is.
> >>
> >> There are a lot of optimizations to make things fast for the common
> >> case - and setting a really high limit makes some of those
> >> ineffective.  Hopefully you don't really need to return the top 5000
> >> cities?
> >> What version of Solr is this? What faceting method is used? Is this a
> >> multi-valued field?  How many unique values are in the city field?
> >> How many docs in the index?
> >>
> >> -Yonik
> >> http://lucenerevolution.org Lucene/Solr Conference, Boston Oct 7-8
> >>
> >>
> >> > FAST - 16ms
> >> > facet.field=city
> >> > f.city.facet.limit=5000
> >> > f.city.facet.sort=lex
> >> >
> >> > FAST - 20 ms
> >> > facet.field=city
> >> > f.city.facet.limit=50
> >> > f.city.facet.sort=count
> >> >
> >> > SLOW - over 1 second
> >> > facet.field=city
> >> > f.city.facet.limit=5000
> >> > f.city.facet.sort=count
> >> >
> >> > Regards
> >> > ericz
> >> >
> >
> >
>


Re: Slow facet sorting - lex vs count

2010-08-25 Thread Eric Grobler
Hi Yonik,

Thanks for your response.

I use Solr 1.41
There are 14000 cities in the index.
The type is just a simple string: 
The facet method is fc.

You are right I do not need 5000 cities, I was just surprised to see this
big difference, there are places where I do need to sort count and return
about 500 items.

If Solr was also slow in locating the highest count city it would be less
surprising.
In other words, if I set the limit to 1, then solr returns Berlin as the
city with the highest count within 3ms which seems to indicate that the
facet is internally sorted by count.
However, the speed regresses linearly, 30ms for 10, 300ms for 1000 etc.

Regards
Eric

On Wed, Aug 25, 2010 at 3:28 PM, Yonik Seeley wrote:

> On Wed, Aug 25, 2010 at 7:22 AM, Eric Grobler 
> wrote:
> > There is a huge difference doing facet sorting on lex vs count
> > The strange thing is that count sorting is fast when setting a small
> limit.
> > I realize I can do sorting in the client, but I am just curious why this
> is.
>
> There are a lot of optimizations to make things fast for the common
> case - and setting a really high limit makes some of those
> ineffective.  Hopefully you don't really need to return the top 5000
> cities?
> What version of Solr is this? What faceting method is used? Is this a
> multi-valued field?  How many unique values are in the city field?
> How many docs in the index?
>
> -Yonik
> http://lucenerevolution.org Lucene/Solr Conference, Boston Oct 7-8
>
>
> > FAST - 16ms
> > facet.field=city
> > f.city.facet.limit=5000
> > f.city.facet.sort=lex
> >
> > FAST - 20 ms
> > facet.field=city
> > f.city.facet.limit=50
> > f.city.facet.sort=count
> >
> > SLOW - over 1 second
> > facet.field=city
> > f.city.facet.limit=5000
> > f.city.facet.sort=count
> >
> > Regards
> > ericz
> >
>


Slow facet sorting - lex vs count

2010-08-25 Thread Eric Grobler
Hi Solr experts,

There is a huge difference doing facet sorting on lex vs count
The strange thing is that count sorting is fast when setting a small limit.
I realize I can do sorting in the client, but I am just curious why this is.

FAST - 16ms
facet.field=city
f.city.facet.limit=5000
f.city.facet.sort=lex

FAST - 20 ms
facet.field=city
f.city.facet.limit=50
f.city.facet.sort=count

SLOW - over 1 second
facet.field=city
f.city.facet.limit=5000
f.city.facet.sort=count

Regards
ericz


Re: Date faceting

2010-08-04 Thread Eric Grobler
Thanks Koji,

It works :-)

Have a nice day.

regards
ericz

On Wed, Aug 4, 2010 at 12:08 PM, Koji Sekiguchi  wrote:

> (10/08/04 19:42), Eric Grobler wrote:
>
>> Hi Solr community,
>>
>> How do I facet on timestamp for example?
>>
>> I tried something like this - but I get no result.
>>
>> facet=true
>> facet.date=timestamp
>> f.facet.timestamp.date.start=2010-01-01T00:00:00Z
>> f.facet.timestamp.date.end=2010-12-31T00:00:00Z
>> f.facet.timestamp.date.gap=+1HOUR
>> f.facet.timestamp.date.hardend=true
>>
>> Thanks
>> ericz
>>
>>
>>
> Your parameters are not correct. Try:
>
>
> facet=true
> facet.date=timestamp
> facet.date.start=2010-01-01T00:00:00Z
> facet.date.end=2010-12-31T00:00:00Z
> facet.date.gap=+1HOUR
> facet.date.hardend=true
>
> If you want to use per-field override feature, you can set them:
>
> f.timestamp.facet.date.start=2010-01-01T00:00:00Z
> f.timestamp.facet.date.end=2010-12-31T00:00:00Z
> f.timestamp.facet.date.gap=+1HOUR
> f.timestamp.facet.date.hardend=true
>
> Koji
>
> --
> http://www.rondhuit.com/en/
>
>


Date faceting

2010-08-04 Thread Eric Grobler
Hi Solr community,

How do I facet on timestamp for example?

I tried something like this - but I get no result.

facet=true
facet.date=timestamp
f.facet.timestamp.date.start=2010-01-01T00:00:00Z
f.facet.timestamp.date.end=2010-12-31T00:00:00Z
f.facet.timestamp.date.gap=+1HOUR
f.facet.timestamp.date.hardend=true

Thanks
ericz


Re: Tree Faceting in Solr 1.4

2010-07-29 Thread Eric Grobler
Hi Erik,

Thanks, -p1 vs -p0 must then be the issue.

On Thu, Jul 29, 2010 at 2:32 PM, Erik Hatcher wrote:

> I use patch -p0, not -p1.  But otherwise that looks the same as what I do.
>
> Can you try again with -p0 and see if it's still an issue?  (or have you
> gotten past this and I've just not caught up with mails yet?)
>
>Erik
>
>
> On Jul 23, 2010, at 10:26 AM, Eric Grobler wrote:
>
>  Hi Erik,
>>
>> I must be doing something wrong :-(
>> I took:
>> svn co https://svn.apache.org/repos/asf/lucene/dev/trunk  mytest
>>  then i copied SOLR-792.path to folder /mytest/solr
>> then i ran:
>>  patch -p1 < SOLR-792.patch
>>
>> but I get "can't find file to patch at input line 5"
>> Is this the correct trunk and patch command?
>>
>> However if I just manually
>>  - copy TreeFacetComponent.java to folder
>> solr/src/java/org/apache/solr/handler/component
>>  - add SimpleOrderedMap _treeFacets; to
>> ResponseBuilder.java
>>  - and make the changes to solrconfig.xml
>> I am able to compile and run your test :-)
>>
>> Regards
>> Eric
>>
>>
>> On Fri, Jul 23, 2010 at 2:37 PM, Erik Hatcher > >wrote:
>>
>>  I've update the SOLR-792 patch to apply to trunk (using the solr/
>>> directory
>>> as the root still, not the higher-level trunk/).
>>>
>>> This one I think is an important one that I'd love to see eventually part
>>> of Solr built-in, but the TODO's in TreeFacetComponent ought to be taken
>>> care of first, to generalize this to N fields levels and maybe some other
>>> must/nice-to-haves.
>>>
>>>  Erik
>>>
>>>
>>>
>>> On Jul 23, 2010, at 3:45 AM, Eric Grobler wrote:
>>>
>>> Thanks I saw the article,
>>>
>>>>
>>>> As far as I can tell the trunk archives only go back to the middle of
>>>> March
>>>> and the 2 patches are from the beginning of the year.
>>>>
>>>> Thus:
>>>> *These approaches can be tried out easily using a single set of sample
>>>> data
>>>> and the Solr example application (assumes current trunk codebase and
>>>> latest
>>>> patches posted to the respective issues). **
>>>>
>>>> **Is a bit of an over-statement!**
>>>> *
>>>> Regards
>>>> Eric*
>>>> *
>>>> On Fri, Jul 23, 2010 at 6:22 AM, Jonathan Rochkind 
>>>> wrote:
>>>>
>>>> Solr does not, yet, at least not simply, as far as I know, but there are
>>>>
>>>>> ideas and some JIRA's with maybe some patches:
>>>>>
>>>>> http://wiki.apache.org/solr/HierarchicalFaceting
>>>>>
>>>>>
>>>>> 
>>>>> From: rajini maski [rajinima...@gmail.com]
>>>>> Sent: Friday, July 23, 2010 12:34 AM
>>>>> To: solr-user@lucene.apache.org
>>>>> Subject: Re: Tree Faceting in Solr 1.4
>>>>>
>>>>> I am also looking out for same feature in Solr and very keen to know
>>>>> whether
>>>>> it supports this feature of tree faceting... Or we are forced to index
>>>>> in
>>>>> tree faceting formatlike
>>>>>
>>>>> 1/2/3/4
>>>>> 1/2/3
>>>>> 1/2
>>>>> 1
>>>>>
>>>>> In-case of multilevel faceting it will give only 2 level tree facet is
>>>>> what
>>>>> i found..
>>>>>
>>>>> If i give query as : country India and state Karnataka and city
>>>>> bangalore...All what i want is a facet count  1) for condition above.
>>>>> 2)
>>>>> The
>>>>> number of states in that Country 3) the number of cities in that state
>>>>> ...
>>>>>
>>>>> Like => Country: India ,State:Karnataka , City: Bangalore <1>
>>>>>
>>>>> State:Karnataka
>>>>>  Kerla
>>>>>  Tamilnadu
>>>>>  Andra Pradesh...and so on
>>>>>
>>>>> City:  Mysore
>>>>>      Hubli
>>>>>  Mangalore
>>>>>  Coorg and so on...
>>>>>
>>>>>
>>&

Re: A German Question

2010-07-29 Thread Eric Grobler
Hi Christian,

Thank you - sounds good - I will try that.

regards
Ericz

On Thu, Jul 29, 2010 at 12:04 PM, Christian Vogler <
christian.vog...@gmail.com> wrote:

> On Thursday 29 of July 2010 14:00:21 Eric Grobler wrote:
> > But faceting then looks like:
> >  molln
> >  munchen
> >  rossdorf
> >
> > How can I enable case-insensitive and german agnostic character filters
> and
> > output proper formatted names in the facet result?
>
> Just create another field without any filtering or conversions, and use the
> copy
> field mechanism to shadow the city names there. Then, facet on that field.
>
> Best regards
> - Christian
>


A German Question

2010-07-29 Thread Eric Grobler
Hi Solr world,

I have a city field with german city names like:
 Mölln
 München
 Roßdorf

and I want to do filters like:
  fq=city:München
or
  fq=city:munchen


I use this type definition:

  



  


But faceting then looks like:
 molln
 munchen
 rossdorf

How can I enable case-insensitive and german agnostic character filters and
output proper formatted names in the facet result?

Thanks
Ericz


Re: LucidWorks 1.4 compilation

2010-07-27 Thread Eric Grobler
I did not realize the LucidWords.jar comes with an option to install the
sources :-)

On Tue, Jul 27, 2010 at 10:59 AM, Eric Grobler wrote:

> Good Morning, afternoon or evening...
>
> If someone installed Solr using the LucidWorks.jar (1.4) installation how
> can one make a small change and recompile.
>
> Is there a LucidWorks (tomcat) build somewhere?
>
> Regards
> ericz
>
>
>
>
>


LucidWorks 1.4 compilation

2010-07-27 Thread Eric Grobler
Good Morning, afternoon or evening...

If someone installed Solr using the LucidWorks.jar (1.4) installation how
can one make a small change and recompile.

Is there a LucidWorks (tomcat) build somewhere?

Regards
ericz


Re: Tree Faceting in Solr 1.4

2010-07-23 Thread Eric Grobler
Hi Erik,

I must be doing something wrong :-(
I took:
svn co https://svn.apache.org/repos/asf/lucene/dev/trunk  mytest
  then i copied SOLR-792.path to folder /mytest/solr
then i ran:
  patch -p1 < SOLR-792.patch

but I get "can't find file to patch at input line 5"
Is this the correct trunk and patch command?

However if I just manually
  - copy TreeFacetComponent.java to folder
solr/src/java/org/apache/solr/handler/component
  - add SimpleOrderedMap _treeFacets; to
ResponseBuilder.java
  - and make the changes to solrconfig.xml
I am able to compile and run your test :-)

Regards
Eric


On Fri, Jul 23, 2010 at 2:37 PM, Erik Hatcher wrote:

> I've update the SOLR-792 patch to apply to trunk (using the solr/ directory
> as the root still, not the higher-level trunk/).
>
> This one I think is an important one that I'd love to see eventually part
> of Solr built-in, but the TODO's in TreeFacetComponent ought to be taken
> care of first, to generalize this to N fields levels and maybe some other
> must/nice-to-haves.
>
>    Erik
>
>
>
> On Jul 23, 2010, at 3:45 AM, Eric Grobler wrote:
>
>  Thanks I saw the article,
>>
>> As far as I can tell the trunk archives only go back to the middle of
>> March
>> and the 2 patches are from the beginning of the year.
>>
>> Thus:
>> *These approaches can be tried out easily using a single set of sample
>> data
>> and the Solr example application (assumes current trunk codebase and
>> latest
>> patches posted to the respective issues). **
>>
>> **Is a bit of an over-statement!**
>> *
>> Regards
>> Eric*
>> *
>> On Fri, Jul 23, 2010 at 6:22 AM, Jonathan Rochkind 
>> wrote:
>>
>>  Solr does not, yet, at least not simply, as far as I know, but there are
>>> ideas and some JIRA's with maybe some patches:
>>>
>>> http://wiki.apache.org/solr/HierarchicalFaceting
>>>
>>>
>>> 
>>> From: rajini maski [rajinima...@gmail.com]
>>> Sent: Friday, July 23, 2010 12:34 AM
>>> To: solr-user@lucene.apache.org
>>> Subject: Re: Tree Faceting in Solr 1.4
>>>
>>> I am also looking out for same feature in Solr and very keen to know
>>> whether
>>> it supports this feature of tree faceting... Or we are forced to index in
>>> tree faceting formatlike
>>>
>>> 1/2/3/4
>>> 1/2/3
>>> 1/2
>>> 1
>>>
>>> In-case of multilevel faceting it will give only 2 level tree facet is
>>> what
>>> i found..
>>>
>>> If i give query as : country India and state Karnataka and city
>>> bangalore...All what i want is a facet count  1) for condition above. 2)
>>> The
>>> number of states in that Country 3) the number of cities in that state
>>> ...
>>>
>>> Like => Country: India ,State:Karnataka , City: Bangalore <1>
>>>
>>>   State:Karnataka
>>>Kerla
>>>Tamilnadu
>>>Andra Pradesh...and so on
>>>
>>>   City:  Mysore
>>>Hubli
>>>Mangalore
>>>Coorg and so on...
>>>
>>>
>>> If I am doing
>>> facet=on & facet.field={!ex=State}State & fq={!tag=State}State:Karnataka
>>>
>>> All it gives me is Facets on state excluding only that filter query.. But
>>> i
>>> was not able to do same on third level ..Like  facet.field= Give me the
>>> counts of  cities also in state Karantaka..
>>> Let me know solution for this...
>>>
>>> Regards,
>>> Rajani Maski
>>>
>>>
>>>
>>>
>>>
>>> On Thu, Jul 22, 2010 at 10:13 PM, Eric Grobler <
>>> impalah...@googlemail.com
>>>
>>>> wrote:
>>>>
>>>
>>>  Thank you for the link.
>>>>
>>>> I was not aware of the multifaceting syntax - this will enable me to run
>>>>
>>> 1
>>>
>>>> less query on the main page!
>>>>
>>>> However this is not a tree faceting feature.
>>>>
>>>> Thanks
>>>> Eric
>>>>
>>>>
>>>>
>>>>
>>>> On Thu, Jul 22, 2010 at 4:51 PM, SR  wrote:
>>>>
>>>>  Perhaps the following article can help:
>>>>>
>>>>>
>>>>
>>> http://www.craftyfella.com/2010/01/faceting-and-multifaceting-syntax-in.html
>>>
>>>>
>>>>> -S
>>>>>
>>>>>
>>>>> On Jul 22, 2010, at 5:39 PM, Eric Grobler wrote:
>>>>>
>>>>>  Hi Solr Community
>>>>>>
>>>>>> If I have:
>>>>>> COUNTRY CITY
>>>>>> Germany Berlin
>>>>>> Germany Hamburg
>>>>>> Spain   Madrid
>>>>>>
>>>>>> Can I do faceting like:
>>>>>> Germany
>>>>>> Berlin
>>>>>> Hamburg
>>>>>> Spain
>>>>>> Madrid
>>>>>>
>>>>>> I tried to apply SOLR-792 to the current trunk but it does not seem
>>>>>>
>>>>> to
>>>
>>>> be
>>>>
>>>>> compatible.
>>>>>> Maybe there is a similar feature existing in the latest builds?
>>>>>>
>>>>>> Thanks & Regards
>>>>>> Eric
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>
>>>
>


Re: Tree Faceting in Solr 1.4

2010-07-23 Thread Eric Grobler
Hi Erik,

Thanks for the fast update :-)
I will try it soon.

Regards
Eric

On Fri, Jul 23, 2010 at 2:37 PM, Erik Hatcher wrote:

> I've update the SOLR-792 patch to apply to trunk (using the solr/ directory
> as the root still, not the higher-level trunk/).
>
> This one I think is an important one that I'd love to see eventually part
> of Solr built-in, but the TODO's in TreeFacetComponent ought to be taken
> care of first, to generalize this to N fields levels and maybe some other
> must/nice-to-haves.
>
>Erik
>
>
>
> On Jul 23, 2010, at 3:45 AM, Eric Grobler wrote:
>
>  Thanks I saw the article,
>>
>> As far as I can tell the trunk archives only go back to the middle of
>> March
>> and the 2 patches are from the beginning of the year.
>>
>> Thus:
>> *These approaches can be tried out easily using a single set of sample
>> data
>> and the Solr example application (assumes current trunk codebase and
>> latest
>> patches posted to the respective issues). **
>>
>> **Is a bit of an over-statement!**
>> *
>> Regards
>> Eric*
>> *
>> On Fri, Jul 23, 2010 at 6:22 AM, Jonathan Rochkind 
>> wrote:
>>
>>  Solr does not, yet, at least not simply, as far as I know, but there are
>>> ideas and some JIRA's with maybe some patches:
>>>
>>> http://wiki.apache.org/solr/HierarchicalFaceting
>>>
>>>
>>> 
>>> From: rajini maski [rajinima...@gmail.com]
>>> Sent: Friday, July 23, 2010 12:34 AM
>>> To: solr-user@lucene.apache.org
>>> Subject: Re: Tree Faceting in Solr 1.4
>>>
>>> I am also looking out for same feature in Solr and very keen to know
>>> whether
>>> it supports this feature of tree faceting... Or we are forced to index in
>>> tree faceting formatlike
>>>
>>> 1/2/3/4
>>> 1/2/3
>>> 1/2
>>> 1
>>>
>>> In-case of multilevel faceting it will give only 2 level tree facet is
>>> what
>>> i found..
>>>
>>> If i give query as : country India and state Karnataka and city
>>> bangalore...All what i want is a facet count  1) for condition above. 2)
>>> The
>>> number of states in that Country 3) the number of cities in that state
>>> ...
>>>
>>> Like => Country: India ,State:Karnataka , City: Bangalore <1>
>>>
>>>   State:Karnataka
>>>Kerla
>>>Tamilnadu
>>>Andra Pradesh...and so on
>>>
>>>   City:  Mysore
>>>Hubli
>>>Mangalore
>>>Coorg and so on...
>>>
>>>
>>> If I am doing
>>> facet=on & facet.field={!ex=State}State & fq={!tag=State}State:Karnataka
>>>
>>> All it gives me is Facets on state excluding only that filter query.. But
>>> i
>>> was not able to do same on third level ..Like  facet.field= Give me the
>>> counts of  cities also in state Karantaka..
>>> Let me know solution for this...
>>>
>>> Regards,
>>> Rajani Maski
>>>
>>>
>>>
>>>
>>>
>>> On Thu, Jul 22, 2010 at 10:13 PM, Eric Grobler <
>>> impalah...@googlemail.com
>>>
>>>> wrote:
>>>>
>>>
>>>  Thank you for the link.
>>>>
>>>> I was not aware of the multifaceting syntax - this will enable me to run
>>>>
>>> 1
>>>
>>>> less query on the main page!
>>>>
>>>> However this is not a tree faceting feature.
>>>>
>>>> Thanks
>>>> Eric
>>>>
>>>>
>>>>
>>>>
>>>> On Thu, Jul 22, 2010 at 4:51 PM, SR  wrote:
>>>>
>>>>  Perhaps the following article can help:
>>>>>
>>>>>
>>>>
>>> http://www.craftyfella.com/2010/01/faceting-and-multifaceting-syntax-in.html
>>>
>>>>
>>>>> -S
>>>>>
>>>>>
>>>>> On Jul 22, 2010, at 5:39 PM, Eric Grobler wrote:
>>>>>
>>>>>  Hi Solr Community
>>>>>>
>>>>>> If I have:
>>>>>> COUNTRY CITY
>>>>>> Germany Berlin
>>>>>> Germany Hamburg
>>>>>> Spain   Madrid
>>>>>>
>>>>>> Can I do faceting like:
>>>>>> Germany
>>>>>> Berlin
>>>>>> Hamburg
>>>>>> Spain
>>>>>> Madrid
>>>>>>
>>>>>> I tried to apply SOLR-792 to the current trunk but it does not seem
>>>>>>
>>>>> to
>>>
>>>> be
>>>>
>>>>> compatible.
>>>>>> Maybe there is a similar feature existing in the latest builds?
>>>>>>
>>>>>> Thanks & Regards
>>>>>> Eric
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>
>>>
>


Solr 3.1 dev

2010-07-23 Thread Eric Grobler
Hi Everyone

I have a few questions :-)

a) Will the next release of solr be 3.0 (instead of 1.5)?

b) How stable/mature is the current 3x version?

c) Is LocalSolr implemented? where can I find a list of new features?

d) Is this the correct method to download the lasted stable version?
svn co https://svn.apache.org/repos/asf/lucene/dev/branches/branch_3x

Thanks & regards
eric


Re: Tree Faceting in Solr 1.4

2010-07-23 Thread Eric Grobler
Thanks I saw the article,

As far as I can tell the trunk archives only go back to the middle of March
and the 2 patches are from the beginning of the year.

Thus:
*These approaches can be tried out easily using a single set of sample data
and the Solr example application (assumes current trunk codebase and latest
patches posted to the respective issues). **

**Is a bit of an over-statement!**
*
Regards
Eric*
*
On Fri, Jul 23, 2010 at 6:22 AM, Jonathan Rochkind  wrote:

> Solr does not, yet, at least not simply, as far as I know, but there are
> ideas and some JIRA's with maybe some patches:
>
> http://wiki.apache.org/solr/HierarchicalFaceting
>
>
> 
> From: rajini maski [rajinima...@gmail.com]
> Sent: Friday, July 23, 2010 12:34 AM
> To: solr-user@lucene.apache.org
> Subject: Re: Tree Faceting in Solr 1.4
>
> I am also looking out for same feature in Solr and very keen to know
> whether
> it supports this feature of tree faceting... Or we are forced to index in
> tree faceting formatlike
>
> 1/2/3/4
> 1/2/3
> 1/2
> 1
>
> In-case of multilevel faceting it will give only 2 level tree facet is what
> i found..
>
> If i give query as : country India and state Karnataka and city
> bangalore...All what i want is a facet count  1) for condition above. 2)
> The
> number of states in that Country 3) the number of cities in that state ...
>
> Like => Country: India ,State:Karnataka , City: Bangalore <1>
>
> State:Karnataka
>  Kerla
>  Tamilnadu
>  Andra Pradesh...and so on
>
> City:  Mysore
>  Hubli
>  Mangalore
>  Coorg and so on...
>
>
> If I am doing
> facet=on & facet.field={!ex=State}State & fq={!tag=State}State:Karnataka
>
> All it gives me is Facets on state excluding only that filter query.. But i
> was not able to do same on third level ..Like  facet.field= Give me the
> counts of  cities also in state Karantaka..
> Let me know solution for this...
>
> Regards,
> Rajani Maski
>
>
>
>
>
> On Thu, Jul 22, 2010 at 10:13 PM, Eric Grobler  >wrote:
>
> > Thank you for the link.
> >
> > I was not aware of the multifaceting syntax - this will enable me to run
> 1
> > less query on the main page!
> >
> > However this is not a tree faceting feature.
> >
> > Thanks
> > Eric
> >
> >
> >
> >
> > On Thu, Jul 22, 2010 at 4:51 PM, SR  wrote:
> >
> > > Perhaps the following article can help:
> > >
> >
> http://www.craftyfella.com/2010/01/faceting-and-multifaceting-syntax-in.html
> > >
> > > -S
> > >
> > >
> > > On Jul 22, 2010, at 5:39 PM, Eric Grobler wrote:
> > >
> > > > Hi Solr Community
> > > >
> > > > If I have:
> > > > COUNTRY CITY
> > > > Germany Berlin
> > > > Germany Hamburg
> > > > Spain   Madrid
> > > >
> > > > Can I do faceting like:
> > > > Germany
> > > >  Berlin
> > > >  Hamburg
> > > > Spain
> > > >  Madrid
> > > >
> > > > I tried to apply SOLR-792 to the current trunk but it does not seem
> to
> > be
> > > > compatible.
> > > > Maybe there is a similar feature existing in the latest builds?
> > > >
> > > > Thanks & Regards
> > > > Eric
> > >
> > >
> >
>


Re: Tree Faceting in Solr 1.4

2010-07-22 Thread Eric Grobler
Thank you for the link.

I was not aware of the multifaceting syntax - this will enable me to run 1
less query on the main page!

However this is not a tree faceting feature.

Thanks
Eric




On Thu, Jul 22, 2010 at 4:51 PM, SR  wrote:

> Perhaps the following article can help:
> http://www.craftyfella.com/2010/01/faceting-and-multifaceting-syntax-in.html
>
> -S
>
>
> On Jul 22, 2010, at 5:39 PM, Eric Grobler wrote:
>
> > Hi Solr Community
> >
> > If I have:
> > COUNTRY CITY
> > Germany Berlin
> > Germany Hamburg
> > Spain   Madrid
> >
> > Can I do faceting like:
> > Germany
> >  Berlin
> >  Hamburg
> > Spain
> >  Madrid
> >
> > I tried to apply SOLR-792 to the current trunk but it does not seem to be
> > compatible.
> > Maybe there is a similar feature existing in the latest builds?
> >
> > Thanks & Regards
> > Eric
>
>


Tree Faceting in Solr 1.4

2010-07-22 Thread Eric Grobler
Hi Solr Community

If I have:
COUNTRY CITY
Germany Berlin
Germany Hamburg
Spain   Madrid

Can I do faceting like:
Germany
  Berlin
  Hamburg
Spain
  Madrid

I tried to apply SOLR-792 to the current trunk but it does not seem to be
compatible.
Maybe there is a similar feature existing in the latest builds?

Thanks & Regards
Eric


Re: multi-valued associated fields

2010-05-13 Thread Eric Grobler
Hi Ahmed

Thanks again for sharing your insight and experience.
I will discuss the multi-core approach with members of our team.

Regards
Eric

On Wed, May 12, 2010 at 9:24 PM, ahammad  wrote:

>
> In our deployment, we thought that complications might arise when
> attempting
> to hit the Solr server with addresses of too many cores. For instance, we
> have 15+ cores running at the moment. At the worst case, we will have to
> use
> all 15+ addresses of all the cores to search all our data. What we
> eventually did was to combine all the cores into a single core, which will
> basically give us a more clean solution. You will get the simplicity of
> querying one core, but the flexibility of modifying cores separately.
>
> Basically, we have all the cores indexing separately. We set up a script
> that would use the index merge functionality of Solr to combine all the
> indexes into a single index accessible through one core. Yes, there will be
> some overhead on the server, but I believe that it's a good compromise. In
> our case, we have multiple servers at our disposal, so this was not a
> problem to implement. It all depends on your data set and the volume of
> documents that you will be indexing.
>
> --
> View this message in context:
> http://lucene.472066.n3.nabble.com/multi-valued-associated-fields-tp811883p813419.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>


Re: multi-valued associated fields

2010-05-12 Thread Eric Grobler
Hi Ahmed,

Interesting, I did not think of a multi-core approach.

I am not sure, but we might have upto 10 different kinds of data to contend
with like property, pets, farming, electronics, travel, auto, jobs, sport
etc that might complicate things.
Also, one practical limitation we have, is that at times we need to sort
across all cores as it were, and return x number of top rows according to a
specific filter.

I will definitely meditate on your multi-core solution.

Regards
Eric




On Wed, May 12, 2010 at 8:08 PM, ahammad  wrote:

>
> I had the same problem as you last year, i.e. indexing stuff from different
> sources with different characteristics. The way I approached it is by
> setting up a multi-core environment, with each core representing one type
> of
> data. Within each core, I had a "data type" sort of field that would define
> what kind of data is stored (i.e. in your case, it would be "auto" or "real
> estate" etc...).
>
> The advantages of this setup is that it allows you to make changes to
> individual cores without affecting anything else. Also, faceting based on
> category is achieved by the data type field. You can do searching on
> multiple cores like you would on a single core, meaning that all the search
> parameters can be applied. Solr will automatically merge all the data into
> one result set. Another advantage is if you index frequently, this way will
> allow you to index at different times and reduce the overall load. Just a
> thought an an approach...
> --
> View this message in context:
> http://lucene.472066.n3.nabble.com/multi-valued-associated-fields-tp811883p813275.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>


Re: multi-valued associated fields

2010-05-12 Thread Eric Grobler
Hi Erick,

Thank your for your thoughts,
I had exactly the same idea like your screenLCD suggestion (but with a
semicolon)
For example:
range1   range2 range3 range_flagsproperties
890 2001   range1;km, range2;kw, range3;year  group;auto,
make;audi, model;a4, color;red
575 2003   range1;km, range2;kw, range3;year  group;auto,
make;nissan, model;primeria, ABS
475 2004   range1;km, range2;kw, range3;year  group;auto,
make;nissan, model;primeria, ABS
4null   null   range1;rooms   group;immo,
type;flat
16   null   null   range1;memory  group;handy,
make;iphone, model;3GS, memory;16GB

The range_flags column will describe the range1, range2, range3 columns so
that you can do queries like:
q=*:*
fq=properties:group;auto
fq=range_flags:range1;km
fq=range1:[2 TO 8]

The range_flag filter is not absolutely nessasary, but it ensures that you
do range queries on the data you intent to.

Regards
Eric

On Wed, May 12, 2010 at 3:12 PM, Erick Erickson wrote:

> I'm not entirely sure this is germane, but there's absolutely no
> requirement
> that
> all documents in SOLR have the same fields. So it's possible for you to
> index
> the "wildly different content" in "wildly different fields" . Then
> searching for
> screen:LCD would be straightforward. Of course this may not map into your
> problem space at all well, but I thought I'd mention it.
>
> There's nothing in SOLR that I know of that understands KEY:VALUE pairs in
> a multi-valued field. However, you could do some trick like prefix your
> key,
> so you'd
> effectively be indexing screenLCD and screenTFT, but that's kind of awkward
> if your
> values have multiple words, although you could still prefix each word (e.g.
> to index a screen with the value "really big one", you'd have to index
> screenreally, screenbig, screenone or some such).
>
> And have you looked at dynamic fields? Again I'm not sure that works for
> you, but
> might be worth a look.
>
> Best
> Erick
>
> On Wed, May 12, 2010 at 4:17 AM, Eric Grobler  >wrote:
>
> > Hi Aditya,
> >
> > Thanks for your response.
> > Yes, a category type would be needed.
> >
> > One thing I am not clear about,
> > If you have multi-values like "toshiba, tecra, LCD"
> > it is then clear that you can run solr queries like:
> >  fq=mymultivaluefield:LCD
> >
> > but for associated fields like:
> >  "make=toshiba, model=tecra, screen=LCD"
> >  "make=toshiba, model=tecra, screen=TFT"
> > Is there a way for Solr to understand key=value pairs from a multi-value
> > field?
> > For example you may want to do a filter on screen type:
> >  fq=mymultivaluefield:screen
> > and not
> >  fq=mymultivaluefield:screen:LCD
> >
> >
> >
> > On Wed, May 12, 2010 at 8:20 AM, findbestopensource <
> > findbestopensou...@gmail.com> wrote:
> >
> > > Hello Eric,
> > >
> > > Certainly it is possible. I would strongly advice to have field which
> > > differentiates the record type (RECORD_TYPE:"CAR" / "PROPERTY").
> > >
> > > >>In general I was also wondering how Solr developers implement
> websites
> > > that
> > > uses tag filters.For example, a user clicks on "Hard drives" then get
> > tags
> > > "External,
> > > Internal" then clicks on "External" and gets "usb, firewire" etc.
> > > By using faceting queries, You could acheive this.
> > >
> > > Regards
> > > Aditya
> > > www.findbestopensource.com
> > >
> > >
> > >
> > >
> > > On Wed, May 12, 2010 at 12:29 PM, Eric Grobler <
> > impalah...@googlemail.com
> > > >wrote:
> > >
> > > > Hallo Solr community,
> > > >
> > > > We are considering Solr for searching on content from various
> partners
> > > > with wildly different content.
> > > >
> > > > Is it possible or practical to work with multi-valued associated
> fields
> > > > like
> > > > this?
> > > > "Make:Audi, Model:A4, Color:Blue, Year:1998, KM:20, Extras:GPS"
> > > > "Type:Flat, Rooms:2, Period:6 months"
> > > > "Make:Toshiba, Model:Tecra, RAM:4GB, Extras:BlueRay;Lock"
> > > > "Breed:Siamese, Age:9 weeks"
> > > >
> > > > and do:
> > > > - searching on individual keys
> > > > - range queries within multi-valued fields.
> > > > - faceting
> > > >
> > > > I suppose an alternative would be to create unnamed fields like
> > > > range1, range2, range3 with a descripter field like
> > > >  "Year,KM,EngineSize" for a car document and
> > > >  "Rooms" for a property document for example.
> > > >
> > > > In general I was also wondering how Solr developers implement
> websites
> > > that
> > > > uses tag filters.
> > > > For example, a user clicks on "Hard drives" then get tags "External,
> > > > Internal" then clicks on "External" and gets "usb, firewire" etc.
> > > >
> > > > Any suggestions and feedback would be greatly appreciated.
> > > >
> > > > Regards
> > > > Eric
> > > >
> > >
> >
>


Re: multi-valued associated fields

2010-05-12 Thread Eric Grobler
Hi Aditya,

Thanks for your response.
Yes, a category type would be needed.

One thing I am not clear about,
If you have multi-values like "toshiba, tecra, LCD"
it is then clear that you can run solr queries like:
  fq=mymultivaluefield:LCD

but for associated fields like:
  "make=toshiba, model=tecra, screen=LCD"
  "make=toshiba, model=tecra, screen=TFT"
Is there a way for Solr to understand key=value pairs from a multi-value
field?
For example you may want to do a filter on screen type:
  fq=mymultivaluefield:screen
and not
  fq=mymultivaluefield:screen:LCD



On Wed, May 12, 2010 at 8:20 AM, findbestopensource <
findbestopensou...@gmail.com> wrote:

> Hello Eric,
>
> Certainly it is possible. I would strongly advice to have field which
> differentiates the record type (RECORD_TYPE:"CAR" / "PROPERTY").
>
> >>In general I was also wondering how Solr developers implement websites
> that
> uses tag filters.For example, a user clicks on "Hard drives" then get tags
> "External,
> Internal" then clicks on "External" and gets "usb, firewire" etc.
> By using faceting queries, You could acheive this.
>
> Regards
> Aditya
> www.findbestopensource.com
>
>
>
>
> On Wed, May 12, 2010 at 12:29 PM, Eric Grobler  >wrote:
>
> > Hallo Solr community,
> >
> > We are considering Solr for searching on content from various partners
> > with wildly different content.
> >
> > Is it possible or practical to work with multi-valued associated fields
> > like
> > this?
> > "Make:Audi, Model:A4, Color:Blue, Year:1998, KM:20, Extras:GPS"
> > "Type:Flat, Rooms:2, Period:6 months"
> > "Make:Toshiba, Model:Tecra, RAM:4GB, Extras:BlueRay;Lock"
> > "Breed:Siamese, Age:9 weeks"
> >
> > and do:
> > - searching on individual keys
> > - range queries within multi-valued fields.
> > - faceting
> >
> > I suppose an alternative would be to create unnamed fields like
> > range1, range2, range3 with a descripter field like
> >  "Year,KM,EngineSize" for a car document and
> >  "Rooms" for a property document for example.
> >
> > In general I was also wondering how Solr developers implement websites
> that
> > uses tag filters.
> > For example, a user clicks on "Hard drives" then get tags "External,
> > Internal" then clicks on "External" and gets "usb, firewire" etc.
> >
> > Any suggestions and feedback would be greatly appreciated.
> >
> > Regards
> > Eric
> >
>


multi-valued associated fields

2010-05-12 Thread Eric Grobler
Hallo Solr community,

We are considering Solr for searching on content from various partners
with wildly different content.

Is it possible or practical to work with multi-valued associated fields like
this?
"Make:Audi, Model:A4, Color:Blue, Year:1998, KM:20, Extras:GPS"
"Type:Flat, Rooms:2, Period:6 months"
"Make:Toshiba, Model:Tecra, RAM:4GB, Extras:BlueRay;Lock"
"Breed:Siamese, Age:9 weeks"

and do:
- searching on individual keys
- range queries within multi-valued fields.
- faceting

I suppose an alternative would be to create unnamed fields like
range1, range2, range3 with a descripter field like
  "Year,KM,EngineSize" for a car document and
  "Rooms" for a property document for example.

In general I was also wondering how Solr developers implement websites that
uses tag filters.
For example, a user clicks on "Hard drives" then get tags "External,
Internal" then clicks on "External" and gets "usb, firewire" etc.

Any suggestions and feedback would be greatly appreciated.

Regards
Eric


Re: Embedded Solr search query

2010-05-11 Thread Eric Grobler
Thank you for the link Camen,

It is a great help.

Have a nice day

Regards
Eric


On Fri, May 7, 2010 at 5:13 PM, caman wrote:

>
> I would just look at SOLR source code and see how standard search handler
> and dismaxSearchHandler are implemented.
>
> Look under package 'org.apache.solr.
> <
> http://hudson.zones.apache.org/hudson/job/Solr-trunk/clover/org/apache/solr
> /handler/pkg-summary.html<http://hudson.zones.apache.org/hudson/job/Solr-trunk/clover/org/apache/solr%0A/handler/pkg-summary.html>>
> handler'
>
>
>
>
>
>
>
> From: Eric Grobler [via Lucene]
> [mailto:ml-node+783212-2036924225-124...@n3.nabble.com
> ]
> Sent: Friday, May 07, 2010 1:33 AM
> To: caman
> Subject: Re: Embedded Solr search query
>
>
>
> Hi Camen,
>
> I was hoping someone has done it already :-)
> I am also new to Solr/lucene, can you perhaps point me to a request handler
> example page?
>
> Thanks and Regards
> Eric
>
> On Fri, May 7, 2010 at 9:05 AM, caman <[hidden email]>wrote:
>
>
> >
> > Why not write a custom request handler which can parse, split, execute
> and
>
> > combine results to your queries?
> >
> >
> >
> >
> >
> >
> >
> > From: Eric Grobler [via Lucene]
> > [mailto:[hidden email]<[hidden email]>
> > ]
> > Sent: Friday, May 07, 2010 1:01 AM
> > To: caman
> > Subject: Embedded Solr search query
> >
> >
> >
> > Hello Solr community,
> >
> > When a user search on our web page, we need to run 3 related but
> different
>
> > queries.
> > For SEO reasons, we cannot use Ajax so at the moment we run 3 queries
> > sequentially inside a PHP script.
> > Allthough Solr is superfast,  the extra network overhead can make the 3
> > queries 400ms slower than it needs to be.
> >
> > Thus my question is:
> > Is there a way whereby you can send 1 query string to Solr with 2 or more
> > embedded search queries, where Solr will split and execute the queries
> and
>
> > return the results of the multiple searches in 1 go.
> >
> > In other words, instead of:
> > -  send searchQuery1
> >   get result1
> > -  send searchQuery2
> >   get result2
> > ...
> >
> > you run:
> > - send searchQuery1+searchQuery2
> > - get result1+result2
> >
> > Thanks and Regards
> > Eric
> >
> >
> >
> >   _
> >
> > View message @
> >
> >
>
> http://lucene.472066.n3.nabble.com/Embedded-Solr-search-query-tp783150p78315
> >
> 0.html<
> http://lucene.472066.n3.nabble.com/Embedded-Solr-search-query-tp78315
> 0p78315%0A0.html<http://lucene.472066.n3.nabble.com/Embedded-Solr-search-query-tp78315%0A0p78315%0A0.html>
> >
> > To start a new topic under Solr - User, email
> > [hidden email]<[hidden email]>
> > To unsubscribe from Solr - User, click
> > < (link removed)
> > GZvcnRoZW90aGVyc3R1ZmZAZ21haWwuY29tfDQ3MjA2OHwtOTM0OTI1NzEx>  here.
> >
> >
> >
> >
> > --
> > View this message in context:
> >
>
> http://lucene.472066.n3.nabble.com/Embedded-Solr-search-query-tp783150p78315
> 6.html<http://lucene.472066.n3.nabble.com/Embedded-Solr-search-query-tp783150p78315%0A6.html>
> > Sent from the Solr - User mailing list archive at Nabble.com.
> >
>
>
>
>   _
>
> View message @
>
> http://lucene.472066.n3.nabble.com/Embedded-Solr-search-query-tp783150p78321
> 2.html
> To start a new topic under Solr - User, email
> ml-node+472068-464289649-124...@n3.nabble.com
> To unsubscribe from Solr - User, click
> < (link removed)
> GZvcnRoZW90aGVyc3R1ZmZAZ21haWwuY29tfDQ3MjA2OHwtOTM0OTI1NzEx>  here.
>
>
>
>
> --
> View this message in context:
> http://lucene.472066.n3.nabble.com/Embedded-Solr-search-query-tp783150p784098.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>


Re: Embedded Solr search query

2010-05-07 Thread Eric Grobler
Hi Svein,
Yes we thought of sending parallell queries, but you still have the extra
network overhead.

Regards
Eric

On Fri, May 7, 2010 at 9:11 AM, Svein Parnas  wrote:

> Or send the queries in parallell from the PHP script (use CURL).
>
> Svein
>
>
> 2010/5/7 caman :
> >
> > Why not write a custom request handler which can parse, split, execute
> and
> > combine results to your queries?
> >
> >
> >
> >
> >
> >
> >
> > From: Eric Grobler [via Lucene]
> > [mailto:ml-node+783150-1027691461-124...@n3.nabble.com
> ]
> > Sent: Friday, May 07, 2010 1:01 AM
> > To: caman
> > Subject: Embedded Solr search query
> >
> >
> >
> > Hello Solr community,
> >
> > When a user search on our web page, we need to run 3 related but
> different
> > queries.
> > For SEO reasons, we cannot use Ajax so at the moment we run 3 queries
> > sequentially inside a PHP script.
> > Allthough Solr is superfast,  the extra network overhead can make the 3
> > queries 400ms slower than it needs to be.
> >
> > Thus my question is:
> > Is there a way whereby you can send 1 query string to Solr with 2 or more
> > embedded search queries, where Solr will split and execute the queries
> and
> > return the results of the multiple searches in 1 go.
> >
> > In other words, instead of:
> > -  send searchQuery1
> >   get result1
> > -  send searchQuery2
> >   get result2
> > ...
> >
> > you run:
> > - send searchQuery1+searchQuery2
> > - get result1+result2
> >
> > Thanks and Regards
> > Eric
> >
> >
> >
> >  _
> >
> > View message @
> >
> http://lucene.472066.n3.nabble.com/Embedded-Solr-search-query-tp783150p78315
> > 0.html
> > To start a new topic under Solr - User, email
> > ml-node+472068-464289649-124...@n3.nabble.com
> > To unsubscribe from Solr - User, click
> > < (link removed)
> > GZvcnRoZW90aGVyc3R1ZmZAZ21haWwuY29tfDQ3MjA2OHwtOTM0OTI1NzEx>  here.
> >
> >
> >
> >
> > --
> > View this message in context:
> http://lucene.472066.n3.nabble.com/Embedded-Solr-search-query-tp783150p783156.html
> > Sent from the Solr - User mailing list archive at Nabble.com.
> >
>


Re: Embedded Solr search query

2010-05-07 Thread Eric Grobler
Hi Camen,

I was hoping someone has done it already :-)
I am also new to Solr/lucene, can you perhaps point me to a request handler
example page?

Thanks and Regards
Eric

On Fri, May 7, 2010 at 9:05 AM, caman wrote:

>
> Why not write a custom request handler which can parse, split, execute and
> combine results to your queries?
>
>
>
>
>
>
>
> From: Eric Grobler [via Lucene]
> [mailto:ml-node+783150-1027691461-124...@n3.nabble.com
> ]
> Sent: Friday, May 07, 2010 1:01 AM
> To: caman
> Subject: Embedded Solr search query
>
>
>
> Hello Solr community,
>
> When a user search on our web page, we need to run 3 related but different
> queries.
> For SEO reasons, we cannot use Ajax so at the moment we run 3 queries
> sequentially inside a PHP script.
> Allthough Solr is superfast,  the extra network overhead can make the 3
> queries 400ms slower than it needs to be.
>
> Thus my question is:
> Is there a way whereby you can send 1 query string to Solr with 2 or more
> embedded search queries, where Solr will split and execute the queries and
> return the results of the multiple searches in 1 go.
>
> In other words, instead of:
> -  send searchQuery1
>   get result1
> -  send searchQuery2
>   get result2
> ...
>
> you run:
> - send searchQuery1+searchQuery2
> - get result1+result2
>
> Thanks and Regards
> Eric
>
>
>
>   _
>
> View message @
>
> http://lucene.472066.n3.nabble.com/Embedded-Solr-search-query-tp783150p78315
> 0.html<http://lucene.472066.n3.nabble.com/Embedded-Solr-search-query-tp783150p78315%0A0.html>
> To start a new topic under Solr - User, email
> ml-node+472068-464289649-124...@n3.nabble.com
> To unsubscribe from Solr - User, click
> < (link removed)
> GZvcnRoZW90aGVyc3R1ZmZAZ21haWwuY29tfDQ3MjA2OHwtOTM0OTI1NzEx>  here.
>
>
>
>
> --
> View this message in context:
> http://lucene.472066.n3.nabble.com/Embedded-Solr-search-query-tp783150p783156.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>


Embedded Solr search query

2010-05-07 Thread Eric Grobler
Hello Solr community,

When a user search on our web page, we need to run 3 related but different
queries.
For SEO reasons, we cannot use Ajax so at the moment we run 3 queries
sequentially inside a PHP script.
Allthough Solr is superfast,  the extra network overhead can make the 3
queries 400ms slower than it needs to be.

Thus my question is:
Is there a way whereby you can send 1 query string to Solr with 2 or more
embedded search queries, where Solr will split and execute the queries and
return the results of the multiple searches in 1 go.

In other words, instead of:
-  send searchQuery1
   get result1
-  send searchQuery2
   get result2
...

you run:
- send searchQuery1+searchQuery2
- get result1+result2

Thanks and Regards
Eric