This the last thing I have to figure out. 

I've got this CF store finder application that does what it's suppose to do. It 
takes
the zipcode and the radius and returned an order list of zipcodes sorted by the
distance from the original zip code entered.  The only problem is when I plug
this list of zip codes, into a query to extract a list of store locations, it 
returns 
the list of stores NOT in the same zipcode order, order by distance. 

Why aren't the stores being returned in the same order as the zipcodes returned?

My query to the stores database that is taking the zipcode ordered list sorted
by distance to the original zipcode entered of "01860" is ...


SELECT     *
FROM         dbo.tblstores
WHERE     (Phone <> '') AND (lat IS NOT NULL) AND (long IS NOT NULL) AND 
(active = 1) AND (zip IN (01860, 03858, 01985, 01913, 03865, 01830, 03827, 
01834, 
                      03848, 01950, 01922, 01832, 01835, 03826, 01833, 01952, 
03811, 03874, 03819, 03844, 01951, 03841, 01969, 03833, 01921, 03079, 03873, 
03842, 
                      01844, 01845, 01841, 01840, 03044, 01843, 01938, 03862, 
01983, 03885, 03042, 01810, 03036, 03087, 03038, 03840, 01949, 03077, 03857, 
01982, 
                      03076, 03870, 01984, 01864, 01929, 01923, 03053, 01826, 
01876, 01850, 03801, 01915, 01852, 03290, 03032, 03824, 01940, 01887, 01960, 
01854, 
                      03051, 01944, 03291, 03854, 03034, 01851, 01867, 03904, 
01930, 01970, 03109, 01862, 01966, 01821, 01880, 03903, 03905, 01879, 01863, 
03060, 
                      01904, 01945, 03103, 03037, 01824, 01803, 02180, 03820, 
01907, 01902, 03825, 03104, 01801, 01905, 01906, 03101, 03062, 01901, 03054, 
03063, 
                      02176, 03102, 03110, 01827, 03106, 01890, 01741, 03261, 
01886, 01730, 02148, 03909, 03869, 01908, 02151, 02173, 02155, 02149, 03908, 
03878, 
                      03049, 03884, 02174))

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:305588
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

Reply via email to