<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Tahoma
}
--></style>
</head>
<body class='hmmessage'>
<BR> Hello,<BR>
 <BR>
thanks it works. <BR>
 <BR>
BR,<BR>
JoJo<BR>

<HR id=stopSpelling>
Date: Tue, 19 Oct 2010 12:53:22 +0200<BR>From: nicklas.aven@jordogskog.no<BR>To: postgis-users@postgis.refractions.net<BR>CC: <BR>Subject: Re: [postgis-users] How to select points within circle<BR><BR>
<META content="Microsoft SafeHTML" name=Generator>
<DIV align=left>Your syntax is a little backwards an it is better to use st_dwithin instead:</DIV>
<DIV align=left> </DIV>
<DIV align=left>select gid, the_geom, floorarea from "building" as m where ST_DWithin(m.geom,'POINT<SPAN style="FONT-FAMILY: Courier New">(306404701,6755737)'::geometry, 200.0</SPAN>);<BR></DIV>
<DIV align=left>HTH</DIV>
<DIV align=left>Nicklas<BR><BR>2010-10-19 zhang zhe wrote:<BR><BR>Hello,<BR>>  <BR>> I have one table called building.sql which contains points. I want to select building which fall within a circle. This circle is not a sql table but instead only coordinate and radius such as <SPAN style="FONT-FAMILY: Courier New">circle(point '(0,0)', 2.0)</SPAN>. <BR>>  <BR>> My sql query is like this <BR>> select gid, the_geom, floorarea from "building" as m where m.geom within(GeoFromText(<SPAN style="FONT-FAMILY: Courier New">circle(point '(306404701,6755737)', 200.0))</SPAN>);<BR>>  <BR>> But it gives me erro. Does anyone knows where went wrong? <BR>>  <BR>> Thanks a lot<BR>>  <BR>> </DIV><BR>_______________________________________________ postgis-users mailing list postgis-users@postgis.refractions.net http://postgis.refractions.net/mailman/listinfo/postgis-users                                     </body>
</html>