<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:st1="urn:schemas-microsoft-com:office:smarttags" xmlns="http://www.w3.org/TR/REC-html40">

<head>
<meta http-equiv=Content-Type content="text/html; charset=us-ascii">
<meta name=Generator content="Microsoft Word 11 (filtered medium)">
<!--[if !mso]>
<style>
v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style>
<![endif]--><o:SmartTagType
 namespaceuri="urn:schemas-microsoft-com:office:smarttags" name="PostalCode"/>
<o:SmartTagType namespaceuri="urn:schemas-microsoft-com:office:smarttags"
 name="City" downloadurl="http://www.5iamas-microsoft-com:office:smarttags"/>
<o:SmartTagType namespaceuri="urn:schemas-microsoft-com:office:smarttags"
 name="place" downloadurl="http://www.5iantlavalamp.com/"/>
<o:SmartTagType namespaceuri="urn:schemas-microsoft-com:office:smarttags"
 name="address" downloadurl="http://www.5iamas-microsoft-com:office:smarttags"/>
<o:SmartTagType namespaceuri="urn:schemas-microsoft-com:office:smarttags"
 name="State" downloadurl="http://www.5iamas-microsoft-com:office:smarttags"/>
<o:SmartTagType namespaceuri="urn:schemas-microsoft-com:office:smarttags"
 name="Street" downloadurl="http://www.5iantlavalampft-com:office:smarttags"/>
<o:SmartTagType namespaceuri="urn:schemas-microsoft-com:office:smarttags"
 name="country-region" downloadurl="http://www.5iantlavalamp.com/"/>
<o:SmartTagType namespaceuri="urn:schemas-microsoft-com:office:smarttags"
 name="PersonName"/>
<!--[if !mso]>
<style>
st1\:*{behavior:url(#default#ieooui) }
</style>
<![endif]-->
<style>
<!--
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman";}
a:link, span.MsoHyperlink
        {color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-compose;
        font-family:Arial;
        color:windowtext;}
@page Section1
        {size:612.0pt 792.0pt;
        margin:72.0pt 90.0pt 72.0pt 90.0pt;}
div.Section1
        {page:Section1;}
-->
</style>

</head>

<body lang=EN-US link=blue vlink=purple>

<div class=Section1>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Hi All,<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p>&nbsp;</o:p></span></font></p>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>I&#8217;m looking for ideas and explanations regarding performance when
publishing maps from ArcSDE and Oracle Spatial, and also with displaying attribute
data from these data source. We have been working for a while now with from these
formats through MapServer and PHP mapscript, and have found the performance has
been disappointing. Specifically, we are trying to use Oracle Spatial (9i) as
well as ArcSDE against both Oracle and SQL Server (we gave up entirely on MS
Access personal geodatabase through OGR). Generally speaking we&#8217;ve found
that map draw operations are substantially slower with these data sources than
if we use Shapefiles; and that the performance hit is even greater with
drawquery operations, especially as the size of the selected feature sets
increases.<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p>&nbsp;</o:p></span></font></p>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>We did some informal testing, both within our MapServer environment to
compare the performance with different data formats, and also between MapServer
and ESRI ArcIMS environments. Here are some of the results we came up with:<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p>&nbsp;</o:p></span></font></p>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>1. We compared MapServer performance with SQL Server ArcSDE and
Shapefiles (with spatial indexes defined for the Shapefiles), with a large
polygon layer representing property parcels (329870 records). To draw the whole
layer at full extents, it took 10 seconds with Shapefiles, 26 with SDE. To zoom
in to a small area, 0.3 seconds with Shapefiles, 2.2 seconds with SDE. These
times are just the draw times reported from the debugging.<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>2. We compared MapServer performance with Oracle Spatial 9i Standard
Edition and Shapefiles, using a polygon layer that has about 6000 records. To
draw the whole layer at full extents, it took 0.29 seconds with Shapefiles,
0.98 with Spatial. To zoom in to a small area, 0.28 seconds with Shapefiles,
0.6 seconds with Spatial. We also tested selected and highlighting features:
select 75 records (querybyrect), 0.5 seconds with Shape, 2.7 with Spatial;
select 3000 records, 0.5 seconds with Shape, 9.4 with Spatial. <o:p></o:p></span></font></p>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>3. We compared MapServer performance with ArcIMS performance using the
same data sources (the property parcel layer with 329870 records). This is an
even more informal test as we didn&#8217;t have access to the same debugging
info on the ArcIMS side, so I will just say that comparing with Shapefiles only,
the 2 platforms were roughly comparable; but ArcIMS speeds up a little with
SDE, while MapServer slows dramatically with this format. <o:p></o:p></span></font></p>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>4. We have even more problems when we want to use the results from the
selection in test 2 to show the attribute data to the user on a separate HTML
form. On the ArcIMS side we can process attribute data quick quickly as the
server sends back an XML file with the attribute data in it. On the MapServer
side the only way we know to publish the attributes is to loop through each
field of each returned record to create the HTML table. Extracting the data in
this fashion is again, for some reason, way faster with Shapefiles as the selection
sets get bigger &#8211; for example with the 3000 record test it took 3.2
seconds for Shapefiles, and 9.4 seconds with Oracle Spatial. When you add those
times to the draw times the Oracle Spatial approach becomes unworkable;
likewise with ArcSDE.<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p>&nbsp;</o:p></span></font></p>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>So, there are some questions in all this that I&#8217;m hoping the
experts on the list can answer: are we doing something wrong, or are these
numbers to be expected, and if the latter, why are these other, supposedly
enterprise type data sources so slow? Is there a better way to get the
attributes onto a form than looping through each record, each field? Are there
steps we can take to optimize the performance of Spatial or SDE with MapServer?<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p>&nbsp;</o:p></span></font></p>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>I know there are lots of other users out there using Spatial and SDE
&#8211; I&#8217;d really appreciate hearing what has worked for you.<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p>&nbsp;</o:p></span></font></p>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Finally, anticipating questions on the testing technique, I do want to
stress the use of the term &#8220;informal&#8221; to describe these tests
&#8211; this was not a formal benchmarking exercise. But the results bear out the
experiences we&#8217;ve been having over months of working with these datasets,
so while the precise times are not to be taken too seriously I think the
general results are representative.<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p>&nbsp;</o:p></span></font></p>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Thanks in advance.<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p>&nbsp;</o:p></span></font></p>

<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p>&nbsp;</o:p></span></font></p>

<div>

<p class=MsoNormal><font size=2 color=navy face="Times New Roman"><span
lang=EN-CA style='font-size:10.0pt;color:navy'>------------------------------</span></font><font
color=navy><span lang=EN-CA style='color:navy'><o:p></o:p></span></font></p>

<p class=MsoNormal><st1:PersonName w:st="on"><font size=2 color=navy
 face="Times New Roman"><span lang=EN-CA style='font-size:10.0pt;color:navy'>Mark
 Adams</span></font></st1:PersonName><font color=navy><span lang=EN-CA
style='color:navy'><o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 color=navy face="Times New Roman"><span
lang=EN-CA style='font-size:10.0pt;color:navy'>General Manager, <U1:PLACE w:st="on"><U1:CITY w:st="on"><st1:place
w:st="on"><st1:City w:st="on">Ottawa</U1:CITY></U1:PLACE></st1:City></st1:place>
Office</span></font><font color=navy><span lang=EN-CA style='color:navy'><o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 color=navy face="Times New Roman"><span
lang=EN-CA style='font-size:10.0pt;color:navy'>DPRA <U1:PLACE w:st="on"><U1:COUNTRY-REGION w:st="on"><st1:place
w:st="on"><st1:country-region w:st="on">Canada</U1:COUNTRY-REGION></U1:PLACE></st1:country-region></st1:place></span></font><font
color=navy><span lang=EN-CA style='color:navy'><o:p></o:p></span></font></p>

<p class=MsoNormal><U1:STREET w:st="on"><U1:ADDRESS w:st="on"><st1:Street
w:st="on"><st1:address tabIndex="0"
 style="BACKGROUND-POSITION: left bottom; BACKGROUND-IMAGE: url(res://ietag.dll/#34/#1001); BACKGROUND-REPEAT: repeat-x"
 w:st="on"><font size=2 color=navy face="Times New Roman"><span lang=EN-CA
  style='font-size:10.0pt;color:navy'>440 Laurier Ave W</span></font></st1:address></st1:Street></U1:ADDRESS></U1:STREET><font
color=navy><span lang=EN-CA style='color:navy'><o:p></o:p></span></font></p>

<p class=MsoNormal><U1:ADDRESS w:st="on"><U1:STREET w:st="on"><st1:address
tabIndex="0"
style="BACKGROUND-POSITION: left bottom; BACKGROUND-IMAGE: url(res://ietag.dll/#34/#1001); BACKGROUND-REPEAT: repeat-x"
w:st="on"><st1:Street w:st="on"><font size=2 color=navy face="Times New Roman"><span
  lang=EN-CA style='font-size:10.0pt;color:navy'>Suite</U1:STREET></span></font></st1:Street></st1:address><font
size=2 color=navy><span lang=EN-CA style='font-size:10.0pt;color:navy'> 200</span></font></U1:ADDRESS><font
color=navy><span lang=EN-CA style='color:navy'><o:p></o:p></span></font></p>

<p class=MsoNormal><U1:PLACE w:st="on"><U1:CITY w:st="on"><st1:place w:st="on"><st1:City
 w:st="on"><font size=2 color=navy face="Times New Roman"><span lang=EN-CA
  style='font-size:10.0pt;color:navy'>Ottawa</U1:CITY></span></font></st1:City></st1:place><font
size=2 color=navy><span lang=EN-CA style='font-size:10.0pt;color:navy'>, <U1:STATE w:st="on"><st1:State
w:st="on">ON</U1:STATE></st1:State> <U1:POSTALCODE w:st="on"><st1:PostalCode
w:st="on">K1R 7X6</U1:POSTALCODE></st1:PostalCode></span></font></U1:PLACE><font
color=navy><span lang=EN-CA style='color:navy'><o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 color=navy face="Times New Roman"><span
lang=EN-CA style='font-size:10.0pt;color:navy'>Phone: 613.782.2326</span></font><font
color=navy><span lang=EN-CA style='color:navy'><o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 color=navy face="Times New Roman"><span
lang=EN-CA style='font-size:10.0pt;color:navy'>Fax: 613.782.2228</span></font><font
color=navy><span lang=EN-CA style='color:navy'><o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 color=navy face="Times New Roman"><span
lang=EN-CA style='font-size:10.0pt;color:navy'>Email: <a
href="mailto:mark.adams@dpra.com" title="mailto:mark.adams@dpra.com">mark.adams@dpra.com</a></span></font><o:p></o:p></p>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>&nbsp;</span></font><font color=navy><span lang=EN-CA style='color:
navy'><o:p></o:p></span></font></p>

<p class=MsoNormal><font size=3 color=navy face="Times New Roman"><span
lang=EN-CA style='font-size:12.0pt;color:navy'><img border=0 width=192
height=54 id="_x0000_i1025" src="cid:image001.jpg@01C6C634.2437E600"
align=baseline></span></font><font color=navy><span lang=EN-CA
style='color:navy'><o:p></o:p></span></font></p>

</div>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p>&nbsp;</o:p></span></font></p>

</div>

</body>

</html>