Solved

Need help doing a dissolve in Oracle

Posted on 2011-02-22
4
1,002 Views
Last Modified: 2013-11-11
I am trying to dissolve a large number of polygons. In ArcGIS the operation simply was not practical so I am trying to do it in Oracle.  For my initial test I am trying this:

 SELECT TRANSTECH,MAXADDOWN,MAXADUP,HOCONAME,HOCONUM,SDO_AGGR_UNION(
  MDSYS.SDOAGGRTYPE(c.shape, 0.005))SHAPE
  FROM ADDRESS_EXTRACT_FC_BUFFER_RI c
  where c.objectid < 101
group by TRANSTECH,MAXADDOWN,MAXADUP,HOCONAME,HOCONUM,SHAPE;

But I am getting the following error:

ORA-22901: cannot compare VARRAY or LOB attributes of an object type
22901. 00000 -  "cannot compare nested table or VARRAY or LOB attributes of an object type"
*Cause:    Comparison of nested table or VARRAY or LOB attributes of an
           object type was attempted in the absence of a MAP or ORDER
           method.
*Action:   define a MAP or ORDER method for the object type.
Error at Line: 12 Column: 54

If I do the aggregate function on the shape column only  it works successfully.  I tried adding an ordered hint but no sucess either.

Any Ideas will be greatly appreciated.
Thanks,
0
Comment
Question by:OR1
4 Comments
 

Accepted Solution

by:
OR1 earned 0 total points
ID: 34954963
I got around the error I was having.  The statement runs without errors not and it gives me the same number of features I would expect from doing it with ArcGIS.  The problem I have now is that it is very slow. It took 1 hour to run on 3335 polygons. If there something I am doing wrong?

select TRANSTECH,MAXADDOWN,MAXADUP,HOCONUM,HOCONAME,SDO_AGGR_UNION(
  MDSYS.SDOAGGRTYPE(c.shape, 0.005))SHAPE
   FROM ADDRESS_EXTRACT_FC_BUFFER_RI c
  group by TRANSTECH,MAXADDOWN,MAXADUP,HOCONUM,HOCONAME;


Also I will have to convert this into something I can export to a new  geodatabase  feature class.  I was thinking about selecting the results of the query into a a table and register it later as a feature class. Does  that sound like the right approach?

Thanks,
0
 
LVL 5

Assisted Solution

by:mrfixit22
mrfixit22 earned 500 total points
ID: 34985603
you can use http://ss64.com/ora/syntax.html exp.  I would like to have the shape file to work with.
If you can let me know and I will give your a place to send it.
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

This article started out as an Experts-Exchange question, which then grew into a quick tip to go along with an IOUG presentation for the Collaborate confernce and then later grew again into a full blown article with expanded functionality and legacy…
Checking the Alert Log in AWS RDS Oracle can be a pain through their user interface.  I made a script to download the Alert Log, look for errors, and email me the trace files.  In this article I'll describe what I did and share my script.
This video shows, step by step, how to configure Oracle Heterogeneous Services via the Generic Gateway Agent in order to make a connection from an Oracle session and access a remote SQL Server database table.
This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now