SDO_DISTANCE - About its performance

Hi, I'm using SDO_DISTANCE in order to obtain the minimum distance between the geometries (polygons) stored in some table. The results are OK but the performance isn't: it takes up to 3 minutes to compute the minimum distance between two of the geometries... while the equivalent PostGIS function with the same data takes only 3 or 4 seconds.
This is the query I'm running:
SELECT
     SDO_GEOM.SDO_DISTANCE(t1.geom, t2.geom, 0.05) as distance
FROM
     mytable t1,
     mytable t2
WHERE
     t1.id = 1 AND
     t2.id = 2;Am I doing something wrong? Thanks!

Dante777,
I looked at your original posting and decided I wouldn't waste the time trying to respond as there just wasn't anything in your posting that I could use to solve your problem.
Follow this:
Hi, I'm using SDO_DISTANCE in order to obtain the minimum distance between the geometries (polygons) stored in some table.You then provide a SQL statement:
SELECT
     SDO_GEOM.SDO_DISTANCE(t1.geom, t2.geom, 0.05) as distance
FROM
     mytable t1,
     mytable t2
WHERE
     t1.id = 1 AND
     t2.id = 2;And then:
Am I doing something wrong?Well, yes you are but it is not what you think.
You simply don't supply any decent information to the hard working people who want to try to help you.
Firstly you forgot to ask:
ID columns have an index right?To whit you answer:
That table has only a spatial index,
How many records do the tables have?To whit you answer:
with only 17 records I don't think it needs more than that.So, you don't answer a direct question about an attribute index rather we have to infer it from the new fact that it has a spatial index (which most users know is irrelevant to sdo_distance's operation) and only 17 records. That is, if it has only "17 records" why do I need an attribute index?
Then you give us some good information that should have been provided up front:
The geometries are quite complex (they have thousands of vertices), but still...OK, so Dante777, "how complex?". This is a potentially critical piece of information. Do you know how to describe that complexity? Perhaps something as easy as:
SELECT
     t1.ID,
     SDO_UTIL.GETNUMVERTICES(t1.geom) as numVertices
FROM
     mytable t1;As an "up front piece of information" it would be very helpful.
Finally, there is an assumption because vital information was not provided up front:
I assume that your geometries are geodetic.To whit you reply:
The data is projected, not geodetic.
I send you an email with the layer in SHP.But could you have provided TWO sdo_geometry objects in the original post obviating the need for emailing shapefiles?
SELECT
     SDO_GEOM.SDO_DISTANCE(sdo_geometry(.....),sdo_geometry(.....), 0.05) as distance
FROM
     dual;So, in summary, this is about an appeal for posters asking for help to provide better information so that they will get an answer back much faster than otherwise and those willing to help will not waste hours and days reading between the lines.
Other forums for other Oracle and non-Oracle products ask for information up front - so should we.
In your case:
1. Whether or not the data is geodetic (SRID will do);
2. Two example geometries in an example SQL statement repliers can run to replicate the problem.
We can't replicate SQL execution on data - mytable - we don't have!
3. Information in indexing, number of rows and geometry complexity.
4. What version of the Oracle database you are running on (not mentioned in this article).
5. Perhaps what Operating System.
6. What client tool are you using? TOAD, SQuirreL, SQL Developer, SQLPlus?
Please everybody who creates a new posting: try and help us to help you.
Simon

Similar Messages

  • Is there any benchmarks about the performance of BI web Intelligence

    Need to know any benchmarks about the performance of business objects web intelligence report against number of records stored in a relational database

    There no as such benchmark. However you can verify the actual time take by report query when fired directly on DB and time taken by Report to execute. and if there is lots of difference, then those report would ideal for tuning.
    e.g. if MOnthwise revenue report takes 5 mins and the actual query takes only 1.5 mins when fired directly on DB. that means something wrong with universe/reports.
    I hope this help you to get started.
    Please share your exp. its interesting to know.
    --Kuldeep

  • I intend to buy new mac pro, is it better to wait for the new OS X mountain, or can buy it and we can update it without affecting its performance?

    I intended to buy new mac pro, is it better to wait for new OS X moutain or can buy it now and update it later as it will not affect its performance???

    khalid.mktaka76 wrote:
    I intended to buy new mac pro, is it better to wait for new OS X moutain or can buy it now and update it later as it will not affect its performance???
    If you can wait about a 3 months after 10.8 is released this summer and upon new hardware you should be in excellent shape to have not only a fastest latest machine, but a OS X version that all the bugs have been worked out. Plus the three free months of Apple hand holding while they figure out what they did wrong with the new OS version.
    If you need a new machine now you'll have to get what you need obviously, but 10.8 should run on it just fine. However know that Apple tweaks things with more currently sellling hardware first, then later gets to the previous released models.
    It's been my guestimation that your good for about two year old hardware with very recent OS X release, three years or older hardware you may want to reconsider sticking with the previous OS X version as your hardware is getting dated and likely has only a year left to go anyway (4 year average), so why bother mucking it up, slowing it down and having to buy all new/updated software and third party hardware because they won't make drivers for your new OS version?

  • My Jetpack 5510L says that its connected to 4G but its performing very slow, I removed the sim card and did a reset of the device. Any other suggestions?

    My Jetpack 5510L says that its connected to 4G but its performing very slow, I removed the sim card and did a reset of the device. Any other suggestions?

    I don't know who you would contact at Verizon to verify this, but I suspect you are in the same situation as me.  My unlimited Jetpack is now being throttled to a basically useless speed of .10Mbps.  Sometimes as low as .04Mbps.  Turns out this is done purposely as they are evidently eliminating unlimited.  They're doing this now even though accounts still display on the my device page as unlimited.  They have given no warning, no explanation and started it in the middle of a billing cycle.  At least for me.  Be prepared to pay about double for 20GB with I think and $8 per gig overage cost.  With the 5GB plan it appears they just throttle down to an unusable speed.  Currently considering saying goodbye to Verizon myself.  Even with some need to change plans and eliminate unlimited this isn't the way to treat customers during the change.

  • HT1515 I'm getting poor performance from my apple TV, will plugging in my airport express via ethernet to apple tv increase its performance (poor wi-fi signal)

    I'm getting poor performance from my apple TV, will plugging in my airport express via ethernet to apple tv increase its performance (poor wi-fi signal)

    Yes, though it is less ideal than what I suggested earlier. You would need to place your AirPort Express in a location approximately midway between your AirPort Extreme Base Station and the TV. Then, using AirPort Utility, configure it to "extend a wireless network".
    It may help. Bear in mind the signal thus "extended" by the Express can only be as good as the signal it can receive from the Extreme. That is the reason for selecting its appoximate midway location.
    Read about it here: http://support.apple.com/kb/HT4145
    Scroll down to "Wirelessly Extended Network (802.11n)" for a picture.
    This solution requires an all-Apple wireless network. No third party stuff.
    You mentioned using Ethernet. That would be a better idea. Scroll down to "Roaming Network (Ethernet-connected Wi-Fi base stations)" for a picture. In your case, the longer the Ethernet cable - hence the closer you can move the Express to the TV - the better

  • About the performance of using shared variables

    Hi
     My system has almost 200 I/O points,I want to the host communicates with PLC using OPC(I had create a OPC I/O Server).
    If I use shared variables bind to OPC data items, there must be almost 200 shared variables.
    And my puzzle is that what's the performance of using these shared variables,will they eat up memory and processor?
    Another question is that if an shared variable will be time-lapse(i.e.,if an OPC data item value change feedback to  program block with 0 delay or not),if so ,then how many millseconds it will delaies? 

    here is a paper about the performance of shared variables.
    Steve Bird
    Culverson Software - Elegant software that is a pleasure to use.
    Culverson.com
    Blog for (mostly LabVIEW) programmers: Tips And Tricks

  • I have recently started a solaris. I have a solaris using 64x and 86x systems and have java. The machine is very active and is very quick. I am happy so far with its performance and think its worthwhile to continue with my projects. That's all I have to s

    I have recently started a solaris. I have a solaris using 64x and 86x systems and have java. The machine is very active and is very quick. I am happy so far with its performance and think its worthwhile to continue with my projects. That's all I have to say.
    John Lupton

    I have recently started a solaris. I have a solaris using 64x and 86x systems and have java. The machine is very active and is very quick. I am happy so far with its performance and think its worthwhile to continue with my projects. That's all I have to say.
    John Lupton

  • About the performance of plumtree portal.

    Please let me ask a question about the performance of plumtree portal.The good reply is not obtained although I have asked the support center in Japan.I saw the log of ptspy.Delay had occurred in the following two points.
    1. Although it is a "<.static.> InetHost::Select(xxxx) is called on 0 write+xx read sockets." part, what processing is performed actually in the message by the plum tree by the processing of inethost.cpp in a WebDownloaderParallel.dll component?
    2. Although it is the part of "CreateFilterContext()-Created new context at address" by the message, is it the operation which is creating the context path for connection with the exterior in PTGWFilter.cpp in a Gateway component?
    Moreover, although delay of processing may occur in these parts, what factor can be considered?
    Thanks,

    Hi, this is Nobuyuki, Plumtree PSO, working for this project.
    I'm attaching snapshot of ptspy from them. I've found that there are two ares which
    seem to take much time.
    1.
    125649 02-22 20:31:23 Debug Gateway 5788 5564 PTGWFilter.cpp(1271) OnEndOfRequest() - called for CtxtPass::TunnelIn <0x2a82210> request125650 02-22 20:31:23 Debug Gateway 5788 5564 PTGWFilter.cpp(232) DeleteContext() - Deleting context at address <0x03CE9478>.125651 02-22 20:31:23 Debug Unified Cache 5988 5936 ptcache.h(2547) PTCache<StoredType, KeySize>::GC() Ending TTL run with 0 item(s) freed!125652 02-22 20:31:23 Debug Unified Cache 5988 5936 ptcache.h(2468) PTCache<StoredType, KeySize>::GC() Starting new TTL run!125653 02-22 20:31:23 Debug Unified Cache 5988 5936 ptcache.h(2547) PTCache<StoredType, KeySize>::GC() Ending TTL run with 0 item(s) freed!125654 02-22 20:31:25 Debug Gateway 5788 3748 PTGWFilter.cpp(198) CreateFilterContext() - Created new context at address <0x03CE9478>.125655 02-22 20:31:25 Debug Gateway 5788 3748 PTGWFilter.cpp(944) OnReadRawData() - Called on new managed request <0x3923f00> with 1460 bytes of data (GET /portal/server.pt?in_hi_userid)125656 02-22 20:31:25 Debug Gateway 5788 3748 PTGWFilter.cpp(1147) OnReadRawData() - Disable Notifications for request <0x3923f00>.(NOT a gateway request)
    Process id of portal is 5988, not 5788.
    2.
    151358 02-22 20:34:27 Performance WebDownloaderParallel.dll 5988 3960 inethost.cpp(1057) 1751857657 : < .static. > InetHost::Select(2104) is called on 0 write + 1 read sockets.151359 02-22 20:34:29 Performance WebDownloaderParallel.dll 5988 3960 inethost.cpp(996) 1751859579 : <0x0A132950> InetHost::Recv(16234) is called for host "http://eippt2.cc.avex.co.jp:80".151360 02-22 20:34:29 Performance WebDownloaderParallel.dll 5988 3960 inethost.cpp(1036) 1751859579 : <0x0A132950> InetHost::Recv(16234) exiting for host "http://eippt2.cc.avex.co.jp:80" in 0 mS.151361 02-22 20:34:29 Performance WebDownloaderParallel.dll 5988 3960 inethost.cpp(1057) 1751859579 : < .static. > InetHost::Select(823) is called on 0 write + 1 read sockets.151362 02-22 20:34:29 Performance WebDownloaderParallel.dll 5988 3960 inethost.cpp(996) 1751859579 : <0x0A132950> InetHost::Recv(16234) is called for host "http://eippt2.cc.avex.co.jp:80".151363 02-22 20:34:29 Performance WebDownloaderParallel.dll 5988 3960 inethost.cpp(1036) 1751859579 : <0x0A132950> InetHost::Recv(16234) exiting for host "http://eippt2.cc.avex.co.jp:80" in 0 mS.151364 02-22 20:34:29 Performance WebDownloaderParallel.dll 5988 3960 inethost.cpp(1057) 1751859579 : < .static. > InetHost::Select(823) is called on 0 write + 1 read sockets.151365 02-22 20:34:29 Performance WebDownloaderParallel.dll 5988 3960 inethost.cpp(996) 1751859594 : <0x0A132950> InetHost::Recv(16219) is called for host "http://eippt2.cc.avex.co.jp:80".151366 02-22 20:34:29 Performance WebDownloaderParallel.dll 5988 3960 inethost.cpp(1036) 1751859594 : <0x0A132950> InetHost::Recv(16219) exiting for host "http://eippt2.cc.avex.co.jp:80" in 0 mS.151367 02-22 20:34:29 Performance WebDownloaderParallel.dll 5988 3960 inethost.cpp(1057) 1751859594 : < .static. > InetHost::Select(813) is called on 0 write + 1 read sockets.151368 02-22 20:34:29 Performance WebDownloaderParallel.dll 5988 3960 inethost.cpp(996) 1751859594 : <0x0A132950> InetHost::Recv(16219) is called for host "http://eippt2.cc.avex.co.jp:80".151369 02-22 20:34:29 Performance WebDownloaderParallel.dll 5988 3960 inethost.cpp(1036) 1751859594 : <0x0A132950> InetHost::Recv(16219) exiting for host "http://eippt2.cc.avex.co.jp:80" in 0 mS.151370 02-22 20:34:29 Performance WebDownloaderParallel.dll 5988 3960 inethost.cpp(1057) 1751859594 : < .static. > InetHost::Select(813) is called on 0 write + 1 read sockets.151371 02-22 20:34:29 Performance WebDownloaderParallel.dll 5988 3960 inethost.cpp(996) 1751859594 : <0x0A132950> InetHost::Recv(16219) is called for host "http://eippt2.cc.avex.co.jp:80".151372 02-22 20:34:29 Performance WebDownloaderParallel.dll 5988 3960 inethost.cpp(1036) 1751859594 : <0x0A132950> InetHost::Recv(16219) exiting for host "http://eippt2.cc.avex.co.jp:80" in 0 mS.151373 02-22 20:34:29 Performance WebDownloaderParallel.dll 5988 3960 httprequest.cpp(1883) 1751859594 : <0x099E9110> HttpRequest::Process(20000) completed one of the requests in 3781 msec.151374 02-22 20:34:29 Performance WebDownloaderParallel.dll 5988 3960 httprequest.cpp(2185) 1751859594 : <0x099E9110> HttpRequest::Process(20000) completed in 3781 msec.
    All lines are Performance type and I guess turning off performance output of ptspy may
    elimnate this bottle neck.

  • Best pratices for the customizing about the performance

    Hello,
    I would like to know the list of the best pratices for the customizing BPC NW 7.5 about the performance.
    Best regards
    Bastien

    Hi,
    There are few how to guides on SDN which will give you a basic idea on script logic. Apart from this, you can refer to the help guide on help. sap.com.
    The templates might also effect the performance. The number of EVDRE functions, the number of expansion dimensions, the number of members on which expansion takes place will effect the performance. A complex formatting in the template will also effect.
    Hope this helps.

  • ITS Performance and Scalability

    Hi,
    Can someone point me to documentation or comment on issues related to ITS performance, stability and error-free performance in a production environment.
    This is with regard to both the standalone ITS 6.20, and the embedded ITS with WAS 6.40
    Thanks.
    NW.

    Hi NW,
    Did Nareshs answer solve your problem?
    If so: Please grant reward points to all authors of helpful answers. If you are satisfied with the solution provided for your question, please mark the topic as answered.
    Best regards,
    Henning.

  • Apple -clueless about its own software !! can anybody give me a straight answer to this ?

    APPLE - clueless about its own software !!! Can anybody please give me a straight answer to this question - how do I zero out my Apple SSD ??
    I have spoken to Apple engineers in-store and via phone support and nobody seems to know how to do it, in fact the guys at the retail store were not even aware that the option for secure erase has been disabled for macs with SSD running Lion. Now im aware that some people will say this is to protect the lifetime of the SSD, but this is irrelevant as Apple SSD's running Lion has TRIM utility. Furthermore to save people's time you cannot do it by externalling booting or by holding down C or CMD+R !
    So, has anyone got a simple method for this, it cant be impossible !
    Please help

    mj25 wrote:
    APPLE - clueless about its own software !!! Can anybody please give me a straight answer to this question - how do I zero out my Apple SSD ??
    I have spoken to Apple engineers in-store and via phone support and nobody seems to know how to do it, in fact the guys at the retail store were not even aware that the option for secure erase has been disabled for macs with SSD running Lion. Now im aware that some people will say this is to protect the lifetime of the SSD, but this is irrelevant as Apple SSD's running Lion has TRIM utility. Furthermore to save people's time you cannot do it by externalling booting or by holding down C or CMD+R !
    So, has anyone got a simple method for this, it cant be impossible !
    Please help
    then if not coming up on google, apple or asking here, then is maybe impossible to do genius. you politeness get you lot of help here.

  • Iphone 4S size is great just improve its performance

    why do apple phones needs to extend its size and forcing its thickness to be much more thin? instead of just improving its performance? I think iPhone 4S design size and thickness is the ideal size for apple handheld phones. people requesting for bigger screen that's why there's an iPad and iPad-mini to meet these demand instead of extending the size of iPhone and to be much more thinner. durability of today's iPhone is gone... even apple's legacy design has gone wrong nowadays because of its bigger size it needs enough space on my pocket.

    Try restoring the iPhone to factory settings. If you are having difficult restoring, put the iPhone into Recovery Mode and see if that then works:
    http://support.apple.com/kb/ht1808
    If not, or if a restore to factory settings does not fix the problem, then your iPhone may have a hardware problem. You can only get the iPhone serviced by Apple in Canada, so you will have to take the iPhone there or send it to someone you know in Canada who can get the iPhone serviced and send it back to you. The only option for getting service in Pakistan would be to pay some unauthorized repair shop to attempt a repair, after which Apple will no longer provide any service even in Canada.
    Regards.

  • Does Linux do anything About SSD Performance Degradation?

    I have been thinking about getting an SSD for my laptop but just read this article on performance degradation of SSDs: http://www.anandtech.com/show/2738/8
    I typically use ext4. Does anyone know if any of the Linux filesystems/kernels/etc do anything about SSD performance degradation? Has anyone found a solution to this problem? Maybe new SSDs don't have the issue?

    My OCZ Vertex 2 SSDs slowed down just a tiny bit soon after installing them, but TRIM seems to be working well and they don't seem to be slowing down any further. I'm running them on ext4 with journaling enabled, and only the log files are being directed to temp files.  Everything else is going to the SSDs, and they are being used just like regular hard drives.

  • How do I eject (or get out somehow) a mini cd I slid into my MacBook Pro CD slot (rather stupidly not thinking about its small size not being a good fit)?

    How do I eject (or get out somehow) a mini cd (3" size) which I slid into my MacBook Pro's CD slot? (Rather stupidly, I admit, not thinking about its small size keeping it from being a good fit.) And of course, it didn't seat on the cd's spindle, and thus is not being "seen" by the computer as being present when I press the eject button, so nothing happens. Because the CD slot has a membrane covering the slot, I can't see in to locate where it is or to try and slip it out manually, either.
    Details about my computer, although I don't know that these are needed, are as follows:
      Model Name:    MacBook Pro
      Model Identifier:    MacBookPro8,1
      Processor Name:    Intel Core i5
      Processor Speed:    2.3 GHz
      Number of Processors:    1
      Total Number of Cores:    2
      L2 Cache (per Core):    256 KB
      L3 Cache:    3 MB
      Memory:    4 GB
      Boot ROM Version:    MBP81.0047.B27

    Thanks for your suggestion, although it didn't work for me. The one that did suggested inserting a sticky note - sticky side down to catch the disk - and slowly pulling it out. I was dubious, but it worked just like magic!

  • I have NAS200 working fine. Of late I found that its performance going down

    I have NAS200 working fine. Of late I found that its performance going down. May lot of stuff delated and coppied on these network drives. Looking for some tool to carry out disk defragmentation and scan disc on network drives. How can I do that without taking out HDD from NAS200

    Defragmentation of a network drive is impossible. Over the network, your computer only has access on a file-by-file basis, not on a sector-by-sector basis.
    If it would be possible to access the disk over the network on a sector-by-sector basis, it wouldn't help anyway because your computer would have to understand the XFS or ext2 filesystem to be able to defragment it, and Windows doesn't understand either.
    Furthermore, because of the way XFS and ext2 work, fragmentation is much less of an issue than with e.g. FAT32.
    If your NAS200 is getting slower over time, it may be possible that your hard disk is slowly but surely dying, and that what you're seeing is that it's correcting low-level errors by retrying reads and writes. It's probably a good idea to check that you have a reliable backup. You do have one, don't you?
    ===Jac
    Frequent NAS200 Answers:
    1. DISABLE the "convert failed logins to guest logins" option to fix permission problems.
    2. NEVER insert or remove hard disks while the power is on. NAS200 doesn't support hot swapping.
    3. ALWAYS use the power button to turn the NAS200 off, don't just unplug it.
    4. Don't trust RAID. Make BACKUPS!
    5. To ACCESS the disks directly, you will need ext2 and/or XFS file systems. I recommend using SystemRescueCD.
    6. Disks will get HOT with standard fan, use "green" disks or consider replacing the fan.
    7. FTP server is insecure and doesn't work behind a NAT router. Use my firmware and SCP instead.
    8. MY FIRMWARE supports SSH shell prompt and SCP for secure file access, and allows running other software.

Maybe you are looking for

  • Transpose of  a Table data

    Hi, i have got two tables called salary and salconfig,salary table is refering to salconfig table. I want a result of transpose values,i.e query should display in the following format. Empid Basic HRA DA TA 298 4500 1500 800 950 300 2300 450 800 560

  • MCE3 : PO value/GR value/Invoice amount/invoice amount

    Once we excute the MCE3 transaction by giving selection parameters as Period from and to and Purchasing Org. When i see the report Vendor     PO Value            GR Value               Invoice amount             invoice amount       X          25761 

  • Automatic deletion of Notes in iphone 5?

    Since I bought iphone 5, all my notes got lost. I have tried to restore from icloud and itunes but nothing comes back. And as soon as I write a new note it gets lost the next day or so. Any solution? Thank you

  • Ooma Mobile Won't Rotate

    The installation of the APP appeared flawed so I called Ooma. By the time I got connected and looked at the APP again, it appeared ready to use with the exception of the screen failing to rotate to landscape. None of the instructions I found regardin

  • Upgrade to CS4 Extended - Pricing

    Is it simply an error in the web store or is there no advantage to upgrading from CS3 extended to CS4 extended over just CS3 (or CS2 or CS1) to CS4 Extended. Its all $349 to upgrade to CS4 extended no matter what Photoshop (CS) version you start from