On Mon, Jul 13, 2009 at 1:32 AM, prads <[email protected]> wrote:

>
> Hello All,
> I am trying to query an item type that i have created. My item type is
> searchhotels and it has a list of hotels with attributes such as hotel
> name , location and its latitude and longitude. I am trying to query
> the same item type to fetch hotels around a location within a 5 mile
> radius. This is the following query i tried
>
> items? [item type:searchhotels] [location:@"South bend, IN, USA"
> +5mi]


Just to make sure, the query you should be executing is (see missing bq):
items?bq=[item type:searchhotels] [location:@"South bend, IN, USA"+5mi]

In addition, if you want better performance, don't query /items but query
/snippets instead. If you want to obtain only your data, then add a
[customer id:12345] where 12345 is your customer id.


I've tested the location queries and they are working as intended, so there
must be something wrong with the way you query using the API:
1) following query with 5mi restrict returns 4 results
snippets?bq=%5Bitem+type%3Asearchhotels%5D+%5Blocation%3A%40%22South+bend%2C+IN%2C+USA%22+%2B5mi%5D
2) following query with no location restrict returns 12 results
snippets?bq=%5Bitem+type%3Asearchhotels%5D

Alex

>
>
> This returns all items (hotels around southbend) that i have uploaded
> in my custom feed. Searching for a 5 mile radius should return only a
> few hotels and not all. So the radius filter isn't working. I am not
> sure if what i am doing is right. I tested this using the Query tool
> provided by Google base. Please let me know if there is anyother way
> of doing it?
>
> -Thanks
> Prads
>
> >
>


-- 
Alex Dovlecel, Google Switzerland GmbH
Company Identifikationsnummer: CH-020.4.028.116-1

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Base Data API" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/Google-Base-data-API?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to