Re: Solr 4.0 = Spatial Search - How to

2011-01-14 Thread Stefan Matheis
caman, how did you try to concat them? perhaps some typecasting would do the trick? Stefan On Fri, Jan 14, 2011 at 7:20 AM, caman aboxfortheotherst...@gmail.comwrote: Thanks Here was the issues. Concatenating 2 floats(lat,lng) at mysql end converted it to a BLOB. Indexing would fail in

Re: Solr 4.0 = Spatial Search - How to

2011-01-14 Thread Stefan Matheis
absolutely no idea why it is a blob .. but the following one works as expected: CAST( CONCAT( lat, ',', lng ) AS CHAR ) HTH Stefan On Fri, Jan 14, 2011 at 9:31 AM, caman aboxfortheotherst...@gmail.comwrote: CONCAT(CAST(lat as CHAR),',',CAST(lng as CHAR)) -- View this message in context:

Re: Solr 4.0 = Spatial Search - How to

2011-01-13 Thread Lance Norskog
Spatial does not support separate separate fields: you don't need lat/long, only 'coord'. To get latitude/longitude in the coord field from the DIH, you need to use a transformer in the DIH script. It would populate a field 'coord' with a text string made from the lat and lon fields:

Re: Solr 4.0 = Spatial Search - How to

2011-01-13 Thread Grijesh.singh
I have used that type of location searching. But I have not used spatial search. I wrote my logic at application end. I have cached the location ids and their lat/lang. When queries are comming for any location say New Delhi then my location searche logic at application end calculate the distance

Re: Solr 4.0 = Spatial Search - How to

2011-01-13 Thread caman
Thanks Here was the issues. Concatenating 2 floats(lat,lng) at mysql end converted it to a BLOB. Indexing would fail in storing BLOB in 'location' type field. After BLOB issue was resolved, all worked ok. Thank you all for your help -- View this message in context:

Solr 4.0 = Spatial Search - How to

2011-01-12 Thread caman
Ok, this could be very easy to do but was not able to do this. Need to enable location search i.e. if someone searches for location 'New York' = show results for New York and results within 50 miles of New York. We do have latitude/longitude stored in database for each record but not sure how to

Re: Solr 4.0 = Spatial Search - How to

2011-01-12 Thread Adam Estrada
I believe this is what you are looking for. I renamed the field called store to coords in the schema.xml file. The tricky part is building out the query. I am using SolrNet to do this though and have not yet cracked the problem.

Re: Solr 4.0 = Spatial Search - How to

2011-01-12 Thread caman
Adam, thanks. Yes that helps but how does coords fields get populated? All I have is field name=lat type=tdouble indexed=true stored=true / field name=lng type=tdouble indexed=true stored=true / field name=coord type=location indexed=true stored=true / fields 'lat' and 'lng' get populated

Re: Solr 4.0 = Spatial Search - How to

2011-01-12 Thread Adam Estrada
Actually, I by looking at the results from the geofilt filter it would appear that it's not giving me the results I'm looking for. Or maybe it is...I need to convert my results to KML to see if it is actually performing a proper radius query.

Re: Solr 4.0 = Spatial Search - How to

2011-01-12 Thread Adam Estrada
In my case, I am getting data from a database and am able to concatenate the lat/long as a coordinate pair to store in my coords field. To test this, I randomized the lat/long values and generated about 6000 documents. Adam On Wed, Jan 12, 2011 at 8:29 PM, caman