Home » SQL & PL/SQL » SQL & PL/SQL » Select Sdo_elem_Info & Sdo_ordinates data (Oracle 10G)
Select Sdo_elem_Info & Sdo_ordinates data [message #418228] Thu, 13 August 2009 08:59 Go to next message
ramzansadiq
Messages: 4
Registered: August 2009
Junior Member
Hi gurus,

I want to select sdo_geometry type data. but no luck with the following. geometry has a "sdo_gemeotry data type", It has collection inside, i haven't found what is the way to get.

select p.geometry.SDO_ORDINATES
from myTable p;

select p.geometry.SDO_ELEM_INFO
from myTable p;

Here is my procedure where I want to get this data using reference cursor.

procedure MyProc
(
north IN Number,
east IN Number,
south IN Number,
west IN Number,
resultData OUT sys_refcursor
) As
Begin
Begin
OPEN resultData FOR
SELECT P.ID ,
P.GEOMETRY.SDO_ELEM_INFO AS longitude,
P.GEOMETRY.SDO_ELEM_INFO AS latitude
FROM MyTable P;
End;
End MyProc;

It's not returning any data..

Please help.
RS
Re: Select Sdo_elem_Info & Sdo_ordinates data [message #418230 is a reply to message #418228] Thu, 13 August 2009 09:09 Go to previous messageGo to next message
Frank
Messages: 7901
Registered: March 2000
Senior Member
What did you use to read the returned ref-cursor?
Re: Select Sdo_elem_Info & Sdo_ordinates data [message #418232 is a reply to message #418228] Thu, 13 August 2009 09:11 Go to previous messageGo to next message
ramzansadiq
Messages: 4
Registered: August 2009
Junior Member
I am using xml file to read ref cursor data.

Is there any way to output ref_cursor data in pl/sql developer.

your help is greatly appreciated.

RS
Re: Select Sdo_elem_Info & Sdo_ordinates data [message #418237 is a reply to message #418232] Thu, 13 August 2009 09:37 Go to previous messageGo to next message
Frank
Messages: 7901
Registered: March 2000
Senior Member
Right-click this procedure and select Test

[Updated on: Thu, 13 August 2009 09:39]

Report message to a moderator

Re: Select Sdo_elem_Info & Sdo_ordinates data [message #418239 is a reply to message #418228] Thu, 13 August 2009 09:46 Go to previous messageGo to next message
ramzansadiq
Messages: 4
Registered: August 2009
Junior Member
Hi Frank,

It ran and doesn't show any data.

Can you please tell me how I can use data from geometry.sdo_elem_info and sdo_ordinates_data. It shows me collection and I can click on a button to see a list of numbers. but haven't found a link to access this data in my SP.






Re: Select Sdo_elem_Info & Sdo_ordinates data [message #418241 is a reply to message #418239] Thu, 13 August 2009 09:52 Go to previous message
Frank
Messages: 7901
Registered: March 2000
Senior Member
1) Install Firefox
2) select the keyword geometry.sdo_elem_info from your post
3) right-click
4) select Search Google for "geometry.sdo_elem_info"
5) read
Previous Topic: Error Msg :ORA-01779: cannot modify a column which maps to a non key-preserved table
Next Topic: Really need help...
Goto Forum:
  


Current Time: Mon Feb 10 04:33:37 CST 2025