<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="IncrediMail 1.0" name=GENERATOR></HEAD>
<BODY style="BACKGROUND-POSITION: 0px 0px; FONT-SIZE: 12pt; MARGIN: 5px 10px 10px; FONT-FAMILY: Arial" bgColor=#ffffff background="" scroll=yes ORGYPOS="0">
<TABLE id=INCREDIMAINTABLE cellSpacing=0 cellPadding=2 width="100%" border=0>
<TBODY>
<TR>
<TD id=INCREDITEXTREGION style="FONT-SIZE: 12pt; CURSOR: auto; FONT-FAMILY: Arial" width="100%">
<DIV>I use Status "On" to Jump and "Default" for Web (browser).</DIV>
<DIV> </DIV>
<DIV>Try it out.</DIV>
<DIV> </DIV>
<DIV>Best wishes</DIV>
<DIV>Ezequias </DIV>
<DIV> </DIV>
<DIV id=IncrediOriginalMessage><I>-------Mensagem original-------</I></DIV>
<DIV> </DIV>
<DIV id=receivestrings>
<DIV dir=ltr style="FONT-SIZE: 11pt"><I><B>De:</B></I> <A href="mailto:jburkhardt@usgs.gov">Jason Burkhardt</A></DIV>
<DIV dir=ltr style="FONT-SIZE: 11pt"><I><B>Data:</B></I> 07/14/05 14:06:15</DIV>
<DIV dir=ltr style="FONT-SIZE: 11pt"><I><B>Para:</B></I> <A href="mailto:postgis-users@postgis.refractions.net">postgis-users@postgis.refractions.net</A></DIV>
<DIV dir=ltr style="FONT-SIZE: 11pt"><I><B>Assunto:</B></I> [postgis-users] Trouble getting PostGIS data to display in MapServer</DIV></DIV>
<DIV> </DIV>
<DIV>I'm really sure this must be something simple I'm missing, but I'm at my</DIV>
<DIV>wits end and am not getting any further by staring at it.  Hopefully a</DIV>
<DIV>fresh set of eyes can help me out.</DIV>
<DIV>I'm running MapServer & have a viewer up displaying data from a variety of</DIV>
<DIV>sources (WMS, .tif's, shapefiles) and would like to include PostGIS data.</DIV>
<DIV>I created a simple PostgreSQL db with a table called cities (this table was</DIV>
<DIV>created with oids) that has a name, state_name and point field.</DIV>
<DIV>I created the point field as such:</DIV>
<DIV>      select AddGeometryColumn('cities', 'point', 4326, 'POINT', 2);</DIV>
<DIV>A sample of the data I'm inserting looks like this:</DIV>
<DIV>      insert into cities (name, state, point) values('Albany', 'NY',</DIV>
<DIV>GeometryFromText('POINT(73 42)',4326));</DIV>
<DIV> </DIV>
<DIV>I then created 2 indexes as so:</DIV>
<DIV>      CREATE INDEX cities_index ON cities USING GIST (point</DIV>
<DIV>GIST_GEOMETRY_OPS)</DIV>
<DIV>      CREATE INDEX cities_index_oid ON cities (name)</DIV>
<DIV>I've also done the second index with point as the unique column, I don't</DIV>
<DIV>really care which it is at this point.</DIV>
<DIV> </DIV>
<DIV>Onto MapServer my layer definition looks like this:</DIV>
<DIV>LAYER</DIV>
<DIV>  CONNECTIONTYPE postgis</DIV>
<DIV>  CONNECTION "user=postgres password=pgadmin dbname=test host=localhost"</DIV>
<DIV>  DATA "point from cities"</DIV>
<DIV>  NAME "PostGIS Cities Test"</DIV>
<DIV>  TYPE POINT</DIV>
<DIV>  STATUS ON</DIV>
<DIV>  CLASS</DIV>
<DIV>      COLOR 255 0 0</DIV>
<DIV>      SIZE 50</DIV>
<DIV>  END</DIV>
<DIV>  PROJECTION</DIV>
<DIV>    "init=epsg:4326"</DIV>
<DIV>  END</DIV>
<DIV>END</DIV>
<DIV> </DIV>
<DIV>Every other layer I have is also 4326.  It's connecting to the database &</DIV>
<DIV>not throwing any errors that I can see from the PostgreSQL logs (I've run</DIV>
<DIV>them with varying levels of verbosity).  MapServer does not return a broken</DIV>
<DIV>image when the layer is turned on, I just don't see the point displayed.</DIV>
<DIV>I would appreciate any comments/insight.</DIV>
<DIV> </DIV>
<DIV>Thanks,</DIV>
<DIV>Jason</DIV>
<DIV> </DIV>
<DIV>_______________________________________________</DIV>
<DIV>postgis-users mailing list</DIV>
<DIV><A href="mailto:postgis-users@postgis.refractions.net">postgis-users@postgis.refractions.net</A></DIV>
<DIV><A href="http://postgis.refractions.net/mailman/listinfo/postgis-users">http://postgis.refractions.net/mailman/listinfo/postgis-users</A></DIV></TD></TR>
<TR>
<TD id=INCREDIFOOTER width="100%">
<TABLE cellSpacing=0 cellPadding=0 width="100%">
<TBODY>
<TR>
<TD width="100%"></TD>
<TD id=INCREDISOUND vAlign=bottom align=middle></TD>
<TD id=INCREDIANIM vAlign=bottom align=middle></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE><SPAN id=IncrediStamp><SPAN dir=ltr><A href="http://www.incredimail.com/index.asp?id=54760"><IMG alt="Add FUN to your email - CLICK HERE!" hspace=0 src="http://www2.incredimail.com/contents/stamps/imstp_emo_pt.gif" align=baseline border=0></A></SPAN></SPAN></BODY></HTML>