Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
dhinasql
Posting Yak Master
195 Posts |
Posted - 2009-01-08 : 02:34:36
|
Dear Friends,We have two table named customer and Zip. Please find the sample data belowCustomerMemId | FirstName | LastName | ZipCode-----------------------------------------12 Dhina T 9213114 ABC DEF 9213115 XYZ K 0100116 UJI OQS 01009ZipZipId | ZipCode | City | State | Latitude | Longitude-------------------------------------------------------------1 92131 HOLTSVILLE NY 40.485500 -73.0240002 01001 BENJAMI NY 42.317017 -72.5150563 01009 BONDSVILLE MA 42.124500 -72.204000This is the sample data for the two tables,Here what we need to do is i have to pass zipcode and distance as a two arguments, and display the customers who are all in the zip within the distance.Please help me in this regards.Thanks in Advance |
|
sakets_2000
Master Smack Fu Yak Hacker
1472 Posts |
Posted - 2009-01-08 : 05:26:32
|
There is an sp to find distnace between 2 sets of latitude and logitudes in this forum. Refer that. |
 |
|
|
|
|