Hi, I've got a table of Sale Reps (ID, Name, Address, City, State, Zipcode, etct). I'm trying to create a stored proc that will accept a ZipCode and search for Reps with that ZipCode. If there isn't an exact match I want the query to expand in increments of 1, up and down, until it finds a rep in the closest ZipCode.
I don't do much SQL, but I have a feeling this is a straightforward query, I'm just not seeing it.
Thanks so much.
-Michael
I don't do much SQL, but I have a feeling this is a straightforward query, I'm just not seeing it.
Thanks so much.
-Michael
Comment