I agree with Kai. This is typically what I do with data in CSV, tab-delimited, XML, KML, etc.  I write a shell script of XSLT transform to convert to a SQL file I can load into PostGIS, the use the pgsql2shp program top convert to shapefile.  This would be more ideal than keeping in PostGIS as MapServer is optimized for shapefiles.  Other than that you could try using C# MapScript to generate layers on-the-fly
<br><br>here's a PHP MapScript example:<br><br>&nbsp;&nbsp;&nbsp; function drawPoint($oMap,$x,$y,$text = '') {<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $nSymbolId = ms_newSymbolObj($oMap, &quot;my_point&quot;);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oSymbol = $oMap-&gt;getsymbolobjectbyid($nSymbolId);
<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oSymbol-&gt;set(&quot;type&quot;, MS_SYMBOL_ELLIPSE);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oSymbol-&gt;set(&quot;filled&quot;, MS_TRUE);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $aPoints[0] = 1;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $aPoints[1] = 1;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oSymbol-&gt;setpoints($aPoints);
<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // Create a layer to hold circle<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oLayerPoints = ms_newLayerObj($oMap);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oLayerPoints-&gt;set(&quot;name&quot;, &quot;my_point_outline&quot; . mt_rand(abs(ceil($x)),abs(ceil($y))));<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oLayerPoints-&gt;set(&quot;type&quot;, MS_LAYER_POINT);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oLayerPoints-&gt;set(&quot;status&quot;, MS_DEFAULT);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $pointObj = ms_newLineObj();<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $pointObj-&gt;addXY($x,$y);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oPointShape = ms_newShapeObj(MS_SHAPE_POINT);
<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oPointShape-&gt;add($pointObj);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if ($text != '') {<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oPointShape-&gt;set(&quot;text&quot;, $text);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oLayerPoints-&gt;addFeature($oPointShape);<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // Create a class object to set feature drawing styles.
<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oMapClass = ms_newClassObj($oLayerPoints);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // Create a style object defining how to draw features<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oPointStyle = ms_newStyleObj($oMapClass);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oPointStyle-&gt;color-&gt;setRGB(250,0,0);
<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oPointStyle-&gt;outlinecolor-&gt;setRGB(255,255,255);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oPointStyle-&gt;set(&quot;symbolname&quot;, &quot;my_point&quot;);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oPointStyle-&gt;set(&quot;size&quot;, &quot;10&quot;);<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // Create label settings for drawing text labels
<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oMapClass-&gt;label-&gt;set( &quot;position&quot;, MS_AUTO);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oMapClass-&gt;label-&gt;color-&gt;setRGB(250,0,0);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $oMapClass-&gt;label-&gt;outlinecolor-&gt;setRGB(255,255,255);<br>&nbsp;&nbsp;&nbsp; }<br>
<br><br><br><div><span class="gmail_quote">On 12/4/06, <b class="gmail_sendername">Kai Behncke</b> &lt;<a href="mailto:kbehncke@igf.uni-osnabrueck.de">kbehncke@igf.uni-osnabrueck.de</a>&gt; wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
On Mon, 4 Dec 2006 11:16:22 +0100, Martijn van Exel wrote<br>&gt; Dear scripters,<br>&gt;<br>&gt; I have a tab-separated text file containing numbered points (number<br>&gt; / x / y). I want to parse this file and put the points on the map as
<br>&gt; numbered dots. How do I go about doing this in (C#) MapScript? Can I<br>&gt; determine the size of the dots and the size, font and colour of the<br>&gt; numbers? Can I make the numbers appear centered inside the dots?
<br>&gt;<br>&gt; Much appreciated,<br>&gt;<br>Hello Martijn,<br>this sounds quite interesting.<br>You can do this easily with PHP/Mapscript.<br>You can parse the text file in a way, that the x and y -koordinates are<br>written in a database (PostgreSQL/PostGIS or even Mysql (even without the
<br>spatial extension)).<br><br>You can determine the size of the dots.<br>For example, if your data are in postgresql/postgis, use a new Layer<br>like:<br><br>LAYER<br>&nbsp;&nbsp;&nbsp;&nbsp; NAME &quot;poi&quot;<br>&nbsp;&nbsp;&nbsp;&nbsp; STATUS on<br>&nbsp;&nbsp;&nbsp;&nbsp; TYPE point
<br>&nbsp;&nbsp;&nbsp;&nbsp; LABELCACHE on<br><br>&nbsp;&nbsp;CONNECTIONTYPE postgis<br>&nbsp;&nbsp;CONNECTION &quot;user=postgres dbname=data host=localhost port=5432&quot;<br>&nbsp;&nbsp;DATA &quot;the_geom from yourtable&quot;<br>LABELITEM 'punktnumber'<br>&nbsp;&nbsp;&nbsp;&nbsp;CLASS<br>
<br><br>&nbsp;&nbsp;STYLE<br>&nbsp;&nbsp; SYMBOL punkt<br>COLOR&nbsp;&nbsp;&nbsp;&nbsp; 120 0 0<br> SIZE 14&nbsp;&nbsp;&nbsp;&nbsp; # this determines the size of the dot<br><br> END<br><br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;LABEL #this determines the label.<br>#You can determine size, font and colour of the
<br># numbers. And you can make the numbers appear centered inside the dots.<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; TYPE truetype<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; FONT &quot;arialbd&quot;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; SIZE 8<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; COLOR 0 0 0<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; OUTLINECOLOR 255 255 255
<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; POSITION cc<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ANGLE auto<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MINFEATURESIZE auto<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;END<br>&nbsp;&nbsp;&nbsp;&nbsp; END<br>END<br><br>Regards, Kai<br>--<br>Dipl.-Geogr. Dipl.-Umweltw. Kai Behncke<br><br>Institut für Geoinformatik und Fernerkundung (IGF)
<br>Universität Osnabrück<br>Kolpingstr. 7<br>49074 Osnabrück<br><br>Raum: 01/308<br>Tel.: +49 541 969-4450<br>E-Mail: mailto:<a href="mailto:kbehncke@igf.uni-osnabrueck.de">kbehncke@igf.uni-osnabrueck.de</a><br>Web:&nbsp;&nbsp;<a href="http://www.igf.uni-osnabrueck.de">
http://www.igf.uni-osnabrueck.de</a><br></blockquote></div><br><br clear="all"><br>-- <br>Regards,<br><br>Mark Thomas<br><a href="mailto:spatialguru.net@gmail.com">spatialguru.net@gmail.com</a><br>205.529.9013<br><br>&quot;Commit to the Lord whatever you do,
<br>&nbsp;&nbsp;&nbsp;&nbsp;and your plans will succeed.&quot; - Proverbs 16:3