This is a discussion on object creation: client versus server within the Oracle Database forums, part of the Database Server Software category; --> Hi! I've got to insert lots of spatial objects. They consist of a bunch of attributes plus two VARRAYs. ...
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| Hi! I've got to insert lots of spatial objects. They consist of a bunch of attributes plus two VARRAYs. Now, I can insert them two ways: 1) insert into ... values (primarykey,sdo_geom(Attrib1...attribn,INFO_ARRAY( ...),ORD_ARRAY(...))) 2) usersession.createoraobject("MDSYS.SDO_GEOMETRY") usersession.createoraobject("MDSYS.SDO_ELEM_INFO_A RRAY" usersession.createoraobject("MDSYS.SDO_ELEM_ORDINA TE_ARRAY" filling the bunch and using a bind variable. Right now, I've got an application that creates the sql string, i.e. method 1. I'm wondering if method two is faster. On one hand, I can use a prepared statement, possibly even array binding. On the other hand, if usersession goes to the database and asks about the structure of the objects it's supposed to create, it's going to do three selects for each geometry to insert. Has anyone tried this and could tell me a hint whether it's worth recoding? Lots of Greetings and Thanks! Volker |