Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Proximity search
Message
De
13/04/2010 14:39:08
 
 
À
13/04/2010 14:29:10
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Versions des environnements
Environment:
VB 9.0
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
MS SQL Server
Application:
Web
Divers
Thread ID:
01459851
Message ID:
01460031
Vues:
18
>>Try using 1.0/111.0
>>
>>or (I have also dropped some parentheses in order to avoid surprises
>>@CenterLat - 1/111 * @SearchDistance
>>
>>also put SearchDistance before /111
>>
>>
>>select * from Test
>> where(latitude between @CenterLat -  @SearchDistance/111.0  and  @CenterLat + @SearchDistance/111.0 ) and
>> (longitude between @CenterLon - @SearchDistance/111.0 and  (@CenterLon + @SearchDistance/111.0) )
>>
>
>This one finds both.
>
>Thanks

It must be related to the float/int mix

Maybe 1/111 evaluates to zero
Gregory
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform