Quick SQL Question
Steve Abaffy <[email protected]>
| Newsgroups | gmane.comp.windows.devel.dotnet.winforms |
|---|---|
| Message-ID | <029601c7972b$82a86390$87f92ab0$@biz> |
Hello,
I am writing an application that looks up addresses. The data is
broken up into prestreetdirection, streetname, poststreetdirection, suffix,
lowaddress and highaddress. All these fields are char fields as we have
lowaddress "numbers" like 312B or 31-A etc...
I have a query that basically has in its where clause,
Where @SuppliedHouseNumber between LowAddress and HighAddress
For the value of @SuppliedHouseNumber='700' the query returns the following
two records
1) LowAddress = 700 , highAddress = 700 which of course is expected,
2) LowAddress = 700 , highAddress = 718 which of course is NOT Expected but
I don't know why.
Any ideas and also how to get around the other problem of
SuppliedHouseAddress = 123 and returns like 1123?
Thanks