<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="City"/>
<o:SmartTagType namespaceuri="urn:schemas-microsoft-com:office:smarttags"
 name="place"/>
<!--[if !mso]>
<style>
st1\:*{behavior:url(#default#ieooui) }
</style>
<![endif]-->
<style>
<!--
 /* Font Definitions */
 @font-face
        {font-family:Wingdings;
        panose-1:5 0 0 0 0 0 0 0 0 0;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        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:blue;
        text-decoration:underline;}
p
        {mso-margin-top-alt:auto;
        margin-right:0in;
        mso-margin-bottom-alt:auto;
        margin-left:0in;
        font-size:12.0pt;
        font-family:"Times New Roman";}
span.EmailStyle18
        {mso-style-type:personal-reply;
        font-family:Arial;
        color:navy;}
@page Section1
        {size:8.5in 11.0in;
        margin:1.0in 1.25in 1.0in 1.25in;}
div.Section1
        {page:Section1;}
-->
</style>
<!--[if gte mso 9]><xml>
 <o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
 <o:shapelayout v:ext="edit">
  <o:idmap v:ext="edit" data="1" />
 </o:shapelayout></xml><![endif]-->
</head>

<body bgcolor=white lang=EN-US link=blue vlink=blue>

<div class=Section1>

<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'>Yes we need an aggregate ConvexHull like upcoming
SQL Server <o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'>http://msdn.microsoft.com/en-us/library/ff929295%28v=sql.110%29.aspx<o:p></o:p></span></font></p>

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

<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'> and Oracle has (since could it be 9.2
</span></font><font size=2 color=navy face=Wingdings><span style='font-size:
10.0pt;font-family:Wingdings;color:navy'>J</span></font><font size=2
color=navy face=Arial><span style='font-size:10.0pt;font-family:Arial;
color:navy'> )  -- <a
href="http://download.oracle.com/docs/cd/B10501_01/appdev.920/a96630/sdo_aggr.htm">http://download.oracle.com/docs/cd/B10501_01/appdev.920/a96630/sdo_aggr.htm</a><o:p></o:p></span></font></p>

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

<p class=MsoNormal><st1:City w:st="on"><st1:place w:st="on"><font size=2
  color=navy face=Arial><span style='font-size:10.0pt;font-family:Arial;
  color:navy'>Regina</span></font></st1:place></st1:City><font size=2
color=navy face=Arial><span style='font-size:10.0pt;font-family:Arial;
color:navy'><o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'><a href="http://www.postgis.us/">http://www.postgis.us</a><o:p></o:p></span></font></p>

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

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

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

<div>

<div class=MsoNormal align=center style='text-align:center'><font size=3
face="Times New Roman"><span style='font-size:12.0pt'>

<hr size=2 width="100%" align=center tabindex=-1>

</span></font></div>

<p class=MsoNormal><b><font size=2 face=Tahoma><span style='font-size:10.0pt;
font-family:Tahoma;font-weight:bold'>From:</span></font></b><font size=2
face=Tahoma><span style='font-size:10.0pt;font-family:Tahoma'>
postgis-users-bounces@postgis.refractions.net
[mailto:postgis-users-bounces@postgis.refractions.net] <b><span
style='font-weight:bold'>On Behalf Of </span></b>Paul Ramsey<br>
<b><span style='font-weight:bold'>Sent:</span></b> Tuesday, July 26, 2011 1:44
PM<br>
<b><span style='font-weight:bold'>To:</span></b> PostGIS Users Discussion<br>
<b><span style='font-weight:bold'>Cc:</span></b> PostGIS Users<br>
<b><span style='font-weight:bold'>Subject:</span></b> Re: [postgis-users] Array
Size Error</span></font><o:p></o:p></p>

</div>

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

<div>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>The problem is you are collecting the whole table into memory before
running the hull operation. There is just an upper limit to the size of tables
you can use that trick on. The solution, says the software developer, is
smarter software, like a convex hull aggregate that builds the hull
progressively, instead if having to first collect all the inputs.<br>
<br>
P.<o:p></o:p></span></font></p>

</div>

<div>

<p class=MsoNormal style='margin-bottom:12.0pt'><font size=3
face="Times New Roman"><span style='font-size:12.0pt'><br>
On 2011-07-26, at 2:44 AM, Paul & Caroline Lewis <<a
href="mailto:paulcaz80@hotmail.com">paulcaz80@hotmail.com</a>> wrote:<o:p></o:p></span></font></p>

</div>

<blockquote style='margin-top:5.0pt;margin-bottom:5.0pt' type=cite>

<div>

<div>

<div>

<div>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Hi All,<br>
The following error has me lost as to finding the solution:<br>
<br>
*****************************************************************************<br>
ERROR: array size exceeds the maximum allowed (1073741823)<br>
---------- Error----------------<br>
ERROR: array size exceeds the maximum allowed (1073741823)<br>
SQL state: 54000<br>
*****************************************************************************<br>
<br>
It happened when using this SQL:<br>
<br>
*****************************************************************************<br>
SELECT ST_ConvexHull(ST_Collect(ST_Force_2D(geom))) FROM table001<br>
*****************************************************************************<br>
This table has 62 million 3D point geometry records, which is one of the small
tables I want to use this function on. <br>
While the server we are running is quite powerful (32GB RAM), we have edited a
lot of system/DB memory settings but I cannot trace any changes we made to the
array size mentioned in the error.<br>
It also seems this query is very similar to this thread:<br>
<br>
<a
href="http://postgis.refractions.net/pipermail/postgis-users/2010-March/026215.html"
target="_blank"><font color="#0068cf"><span style='color:#0068CF'>http://postgis.refractions.net/pipermail/postgis-users/2010-March/026215.html</span></font></a><br>
<br>
However, I cannot ascertain if a solution was found in this thread and was
wondering if anyone has seen this problem.<br>
The error's array size is 1GB I believe (if the number is bytes) but we have
not changed any settings that reference 1GB, does anyone know where this array
limit error is coming from. I have a similar system to that mentioned in the
thread above but for a Postgresql 9 install. The DB is fine other than this
error where more complex bounding box queries on the 3D geoms are working.<br>
<br>
Any help/info would be much appreciated.<br>
<br>
Paul <o:p></o:p></span></font></p>

</div>

</div>

</div>

</div>

</blockquote>

<blockquote style='margin-top:5.0pt;margin-bottom:5.0pt' type=cite>

<div>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>_______________________________________________<br>
postgis-users mailing list<br>
<a href="mailto:postgis-users@postgis.refractions.net">postgis-users@postgis.refractions.net</a><br>
<a href="http://postgis.refractions.net/mailman/listinfo/postgis-users">http://postgis.refractions.net/mailman/listinfo/postgis-users</a><o:p></o:p></span></font></p>

</div>

</blockquote>

</div>

</body>

</html>