Jan 28, 2010

Search Service Part 2 – What can I search?

In my last post I described the various ways you can search using the new Search Service. This post I am focusing on what you can search; in other words, the data that is available in the Service.

What you can search against:

Hosted Data
These are data tables that MapQuest keeps on its own servers for you to search against. There are two main types of Hosted Data: those we provide (like the NAVTEQ POI tables) and those you can upload yourself through our Data Manager tool on the Developer Network.
There are a whole bunch of tables we have up for searching against. The documentation contains a full list of the tables. Clicking on each table name will show you the table schema. Some tables are not actually for spatial searching, but contain the category names for the records in the main table. Not all tables are available for all editions, so it is a good idea to check the documentation to make sure the appKey you are using has access.
If you don’t specify any data sources to search, we’ll use MQA.NTPois as the default. Everyone has access to this one and it contains over 2 million POIs across 50+ categories. The category names are in the MQA.NTPoisCat table. Use the RecordInfo function to retrieve rows from HostedData tables without doing a spatial search.
For your own tables, you can upload whatever points you want – it’s your table. Each table you create has 20 default fields, including a record ID, a name, address fields, phone numbers, and of course latitude & longitude (without which we couldn’t do the searching!) Don’t worry if you don’t have the co-ordinates, we’ll geocode anything on the way through. You can then create up to 100 additional fields for the table, calling them whatever you want.
I’ll go into more depth on the Data Manager tool in another post, but to summarize: you can create your own data tables on our server and upload your records into it. We’ll geocode the records for you if you need, and then store them with a unique HostedData name that you can then search against using the Search Service. Only you have access to your table, so we check the name against your appKey, to make sure it is you using it.
Remote Data
If you have some of your own data that you want to search, and you don’t want to host it in our databases, that’s fine. You can still search it by passing it in to the search function using the RemoteData parameter. Remember that you are passing this data as part of a GET or POST, so you want to be aware of size limitations, and impact to latency and speed! Don’t be surprised if you pass a massive chunk of data over the wire and things take a little longer.
Map data
You can also search the underlying data we use to make the maps. When you do this, you can get back points, lines or polygons that you could use, for example, to draw interactive shapes on a map. Be aware that the map data is also broken down into different data sets, so you should refer to the documentation to make sure you are searching in the country you want to search in. There’s also a list on the same page of the different map features you can search for, so you can limit your search to, for example, getting the polygons of all the parks that are within 20 miles of the center of Washington D.C.

And that’s part 2 done! Next post I’ll go over some of the cool miscellaneous features of the Search Service. More details are, as always, available on our Developer Network Beta Release page.

If you haven’t tried any of our new services and SDKs in Beta yet, you can sign up for an appKey here.

Stay tuned…more to follow soon.

Follow @MapQuestTech on Twitter

MapQuest DevBlog RSS

Want to stay updated on all the latest advances? Subscribe to our blog feed and be among the first to receive the news!