Result of sdo_within_distance

Hello everyone,
I use following select to get the shortest distance from a point to different geometry objects in a table:
SELECT /*+ ORDERED INDEX( p SK_2006_SPA_SX */
sdo_geom.sdo_distance(p.geom, center.geom, 0.5, 'unit=METER') distanceToReferencePoint
FROM protection_area.sk_2006_spa p,
(SELECT SDO_GEOMETRY(2001, 8307, SDO_POINT_TYPE(19.427215576171875, 48.815730794270834, NULL), NULL, NULL) geom FROM dual) center
WHERE MDSYS.SDO_WITHIN_DISTANCE( p.geom, center.geom, 'distance=2000 unit=METER') = 'TRUE'
ORDER BY distanceToReferencePoint
The distance is set to 2000 meter, but the resultset shows 2999,78 meter?
How can be the result greater than 2000 meter?
The geom object that failed has an 2004 gtype - other objects works correctly.
Thanks for your help,
Matthias
Message was edited by:
Matthias Reining
P.S. I use Oracle 10.2.01.0 running on RedHat

Hi,
This post helped me a lot once.
Re: SDO_WITHIN_DISTANCE
Hope it helps,
Luiz

Similar Messages

  • Wrong result with SDO_WITHIN_DISTANCE

    Hi All,
    If you write a query with spatial condition using the SDO_WITHIN_DISTANCE operator and if, in your table there are polylines that have any two consecutive points that are identical, then, the result of the query is inexact. It seems that these polylines are queried on the primary filter only and the secondary filter is ignored.
    Is this bug a known bug and how is it possible to fix it?
    Thanks
    Hugues
    null

    Hello,
    It's not easy to send a sample, but easy to reproduce. As I said any two points have to be consecutive on a polyline.
    As they are consecutice, when validating the geometry, the following Oracle error pops up:
    "ORA-13356 adjacent points in a geometry are redundant"
    Best
    Hugues

  • How to resolve VALIDATE_GEOMETRY_WITH_CONTEXT 'errors'?

    Hello,
    I have some problem to select my spatial data (see Result of sdo_within_distance ). Sometime I select data and my database connection will be separated (ORA-03113, ORA-03114).
    Now I try to analys my data with VALIDATE_GEOMETRY_WITH CONTEXT:
    SELECT c.SPA_CODE, SDO_GEOM.VALIDATE_GEOMETRY_WITH_CONTEXT(c.GEOM, 0.5)
    FROM protection_area.sk_2006_spa c
    WHERE SDO_GEOM.VALIDATE_GEOMETRY_WITH_CONTEXT(c.GEOM, 0.5)<>'TRUE'
    ORDER BY c.SPA_CODE
    Here a part of the result:
    1     SKCHVU002     13348 [Element <1>] [Ring <2>]
    2     SKCHVU003     13349 [Element <1>] [Ring <1>][Edge <5247>][Edge <5252>]
    3     SKCHVU004     13367 [Element <5>] [Ring <1>]
    4     SKCHVU009     13348 [Element <1>] [Ring <14>]
    5     SKCHVU010     13348 [Element <2>] [Ring <1>]
    6     SKCHVU013     13348 [Element <1>] [Ring <8>]
    7     SKCHVU015     13348 [Element <6>] [Ring <7>]
    8     SKCHVU016     13349 [Element <3>] [Ring <1>][Edge <2175>][Edge <2178>]
    9     SKCHVU017     13367 [Element <5>] [Ring <2>]
    10     SKCHVU018     13349 [Element <9>] [Ring <1>][Edge <5368>][Edge <5370>]
    11     SKCHVU019     13348 [Element <14>] [Ring <29>]
    12     SKCHVU021     13367 [Element <1>] [Ring <1>]
    13     SKCHVU025     13367 [Element <1>] [Ring <13>]
    What can I do to avoid this 'errors'?
    I already tried this:
    UPDATE protection_area.sk_2006_spa c
    SET c.GEOM = SDO_UTIL.REMOVE_DUPLICATE_VERTICES(c.geom,0.5)
    Any hints?
    Thanks,
    matthias

    Hi,
    You need to correct those geometries.
    I've got this from Oracle Spatial 10g User's Guide:
    Rings: A ring is only used with polygon elements. Exterior rings in a polygon are
    considered polygon elements, and an exterior ring can include zero or more
    interior rings (or holes). Each interior ring has its own ring designation, but Ring 1
    is associated with the exterior polygon itself. For example, Element 1, Ring 1 refers to the first exterior polygon in a geometry; Element 1, Ring 2 refers to the first interior polygon of the first exterior polygon; and Element 1, Ring 3 refers to the second interior polygon. If the geometry is a multipolygon, Element 2, Ring 1 is
    used to refers to the second exterior polygon. If there are interior polygons
    associated with it, Element 2, Ring 2 refers to the first interior polygon of the
    second exterior polygon.
    Edges: An edge refers to a line segment between two coordinates. Edge 1 refers to the segment between coordinate 1 and coordinate 2, Edge 2 refers to the line segment between coordinates 2 and 3, and so on. The most common place to see edge errors when validating geometries is with self-intersecting polygons. (The Open Geospatial Consortium simple features specification does not allow a
    polygon to self-intersect.) In such cases, Oracle reports error 13349 (polygon
    boundary crosses itself), including the Element, Ring, and Edge numbers where
    self-intersection occurs.
    Hope it helps,
    Luiz

  • Does any one help for SDO_WITHIN_DISTANCE query?

    I tried to use SDO_WITHIN_DISTANCE to find all records that fall in 5 mile radius from the location I searched. The results return the records of Longitude + 5 instead of 5 mile of the location.
    My query was:
    SELECT *
    FROM BH_ORDER_T
    WHERE SDO_WITHIN_DISTANCE(od_pair_geometry,mdsys.SDO_GEOMETRY(2001, 8307, mdsys.SDO_POINT_TYPE(-81.4373367,41.3875542,null), null,null),'DISTANCE=5 UNIT=MILE') = 'TRUE'
    This location is SOLON City Hall, SOLON, OH
    The output results are all records that od_pair_geometry column Longitude between -81 and - 84. For example:
    Sandusky OH (2002,8307,Null,(1,2,1),(-75.46,41.24,-82.71,41.45))
    Elyria OH (2002,8307,Null,(1,2,1),(-75.46,41.24,-82.12,41.38))
    Cleveland OH (2002,8307,Null,(1,2,1),(0,0,-81.7436,41.4336))
    What was wrong with my Query?
    Thanks in advance

    Hi,
    Can you describe what are you doing.
    HSQL demo environment have been startted and when you
    run a job, it's closed DB?
    Regards,
    MAI wanna do data integration from Oracle to HSQLDB, but when connect to hsqldb, it had something wrong just like i had described.
    I fixed it by using demo environment of hsqldb 1.7 instead of 1.8.0, it runs ok.
    but still don't know why v1.8.0 is wrong.

  • Issues to use SDO_WITHIN_DISTANCE

    I tried to use SDO_WITHIN_DISTANCE to find all records that fall in 5 mile radius from the location I searched. The results return the records of Longitude + 5 instead of 5 mile of the location.
    My query was:
    SELECT *
    FROM BH_ORDER_T
    WHERE SDO_WITHIN_DISTANCE(od_pair_geometry,mdsys.SDO_GEOMETRY(2001, 8307, mdsys.SDO_POINT_TYPE(-81.4373367,41.3875542,null), null,null),'DISTANCE=5 UNIT=MILE') = 'TRUE'
    This location is SOLON City Hall, SOLON, OH
    The output results are all records that od_pair_geometry column Longitude between -81 and - 84. For example:
    Sandusky OH (2002,8307,Null,(1,2,1),(-75.46,41.24,-82.71,41.45))
    Elyria      OH (2002,8307,Null,(1,2,1),(-75.46,41.24,-82.12,41.38))
    Cleveland OH (2002,8307,Null,(1,2,1),(0,0,-81.7436,41.4336))
    What was wrong with my Query?
    Thanks in advance

    Hi,
    Can you post a bit more information?
    What version of Oracle Spatial are you using?
    Can you post an example query?
    Can you post the contents of user_sdo_geom_metadata for the table?
    What kind of index are you using?
    Thanks.

  • SDO_NN and SDO_WITHIN_DISTANCE return distance on way or on straight line?

    Hi to all,
    I want ask you if the distance between 2 points computed with SDO_NN and SDO_WITHIN_DISTANCE is a distance on the way that connects these two points (for example 35 miles) or is a distance on a straight line that connects these two points (for example 20 miles)?
    thank you very much.

    Ok Jack, thank you.
    I understood. For straight line I mean a distance that doesn't pass for the streets but on the earth without considering the streets (distance as the crow flies).
    Do you confirm that this result is a distance as the crow flies?
    Thank you very much.

  • Can I put more than one user under one Apple ID account. I want to let other family members use imessage on their own Apple device. Or is there another way to get this end result?

    Can I put more than one user under one Apple ID account. I want to let other family members use imessage on their own Apple device. Or is there another way to get this end result?

    You can seach the net for solutions like this one http://appletvvpn.com/how-to-connect-apple-tv-2-to-vpn/ another idea is to use a PC as the control and fit that with a wireless card and set up a ad hoc wireless network that the Apple TV uses. 

  • Refresh of Data in Xcelsius from Web Intelligence Results

    Hello,
    I am new to the forum but not to Business Objects/Xcelsius.  I attended the SAP Sapphire Event last May and spent time in the Business Objects lab.  Two Product Managers demonstrated how I would be able to refresh the data in an Xcelsius dashboard using Live Office by retreiving results from a Webi document without refreshing the Webi query. 
    For example, my Webi document contains 100,000 result rows.  I want to be able to select a dropdown in my dashboard and have Live Office retreive only a subset of the 100,000 rows.  This being done without having the Webi query being refreshed from the database.  The Webi query would be refreshed nightly.
    The Product Managers advised that this functionality would be available in Service Pack 3 or before.  As of now I cannot find out how to make this work.  Any help or information would be appreciated.  Thanks.

    Hello Charles,
    WebIntelligence Input Controls are a way to enhance and customize user experience with report filters, they are therefore based on report filters and the feature is more focused on user interface & experience rather than exposition outside web intelligence.
    Anyway, AFAIK, report filters are not available from Live Office report parts, you can only filter content with prompts, which requires the document to be refresh from the database, which has a direct impact on performance and scalability for consumers.
    However, if you are with WebIntelligence XI 3.1 SP2 you have the alternative to publish from WebI Rich Client, report elements (any table or chart) as web services (called BI Services).
    This tool is based on Qaaws technology, and share some of its features (main being that is uses the same Xcelsius Data Manager connection), it exposes a large part of WebI interactions to external consumers (esp. Xcelsius) : report filters, drill, prompts.
    Besides this tool provides a set of call input parameters to tune web service consumption for best performance and scalability, enabling to leverage WebI document management features like scehduling, publishing and refresh, so consumers can balance performance with real-time data.
    More information is available from WebIntelligence Rich Client user documentation from section sharing webi content with other web applications.
    I recommend you install the latest fix pack (SP2.5 and above), as some initial fixes were required to ensure full compatibility with Xcelsius.
    Hope that helps,
    David.

  • When i login to yahoo, my first click results in the spinning wheel. Could i have a virus Or why does it only happen when i login to yahoo?

    When i login to yahoo, my first click results in the spinning wheel. Could i have a virus? Or why does it only happen when i login to yahoo?

    Firefox allows to select part of a word. You can select a word with a double click and use Shift + left click to set the end of the selection, so you need to click at the end of the last word instead of in it.

  • Sales Analysis Report - Items -- blank result

    Hi,
    I'm testing a setup and running the sales analysis report. It works for the Customer version but I get no results when running on Items.
    I'm on SBO 2007A SP01 PL07. There are open and closed invoices for inventory items; no credit memos have been posted. All Item type invoices.
    When I run by Customer, I get the correct data - open and closed invoices for that customer.
    When I run by Items, I get no results. The date range is the same for both reports.
    When I run the purchase analysis on Items, I get data for the same items I am trying to see in the sales analysis.
    Any ideas what could be causing this?
    Thank you,
    Heather

    HI Gordon,
    I left the default settings: 
    - Annual Report, Invoices, Individual Display, No Totals
    - Posting Date:  whole fiscal year
    - Main selection:  left blank/default (group = all, no properties)
    I have double/triple/quadruple-check even the Secondary SElection to make sure there's nothing there.
    I have also run it on Due Date instead of Posting Date, still no results (if run on Items).
    As I mentioned, the selection criteria is what I want but for some reason that one version, Items, does not work. The other 2 tabs work with the same selection.
    Heather

  • BW Web Report Issue - Result set too large

    Hi,
    When I execute a BEx Query on Web I am getting “Result set too large ; data retrieval restricted by configuration (maximum = 500000 cells)”.
    Following to my search in SDN I understood we can remove this restriction either across the BW system globally or for a specific query at WAD template.
    In my 7x Web template I am trying to increase default max no of rows parameters, As per the below inputs from SAP Note: 1127156.
    But I can’t find parameter “Size Restriction for Result Sets” for any of the web items (Analysis/Web Template properties/Data Provider properties)….in the WAD Web template
    Please advise where/how can I locate the properites
    Instructions provided in SAP Note…
    The following steps describe how to change the "safety belt" for Query Views:
    1. Use the context menu Properties / Data Provider in a BEx Web Application to maintain the "safety belt" for a Query View.
    2. Choose the register "Size Restriction for Result Sets".
    3. Choose an entry from the dropdown box to specify the maximum number of cells for the result set.
                  The following values are available:
    o Maximum Number
    o Default Number
    o Custom-Defined Number
                  Behind "Maximum Number" and "Default Number" you can find the current numbers defined in the customizing table RSADMIN (see below).
    4. Save the Query View and use it in another Web Template.
    Thanks in advance

    Hi Yasemin,
    Thanks for all help...i was off couple of days.
    To activate it I can suggest to create a dummy template, add your query in it, add a menu bar component add an action to save the query view. Then you run the template and change the size restriction for result set then you can save it by the menu.
    Can you please elaborate on the solution provided,I created dummy template with analysis and Menu bar item...i couldn't able to configure menu bar item...
    Thanks in advance

  • IR: aggregation result in report footer

    Hello!
    This quote from "Beginning Oracle Application Express 4.2" at page 174 (about aggregation in IR):
    "The results are displayed at the end of the report."
    There is a simple method to print the results of aggregation to the report footer on each page?

    I asked - and I answered
    For making this I create on-Demand process for calculation results of aggregation (using APEX_IR_PKG) and make ajax request to him in "After Refresh" event of IR.
    There is the detailed manual with sample http://devsonia.ru/2013/11/14/oracle-apex-aggregation-in-interactive-report-on-each-page-en/.

  • TS2518 Help, I had aperture open and working on a image and did not have a battery in and bumped the power off. As a result it will not open my master, it is locked. when I try to open that Library  it says There was an error opening the database for the

    Help, I had aperture open and working on a image and did not have a battery in and bumped the power off. As a result it will not open my master, it is locked. when I try to open that Library  it says There was an error opening the database for the library. I have tried every thing. I updated the other libr but now it will not open the main to update. What do I do?

    Try starting Aperture with the command and option keys held down.  You'll get 3 options.
    Try each, starting at the top, in order, checking after each to see if it fixes the issue.

  • How can i display the result of java class in InputText ?

    Hi all,
    How can i get the result of java class to InputText Or OutputText ???
    also can every one in the forum give me road map for dealing with java in oracle adf because i'm beginner in oracle adf
    i saw some samples in oracle adf corner but it's difficult for me.

    User,
    Always mention your JDev version, technologies used and clear usecase description (read through this announcement : https://forums.oracle.com/forums/ann.jspa?annID=56)
    How can i get the result of java class to InputText Or OutputText ???Can you elaborate on your requirement? Do you mean the return value of a method in a class as output text? Or an attribute in your class (bean?) as text field?
    -Arun

  • How can I use ONE Text search iView to event/affect mutliple Result Sets?

    hello everyone,
    i have a special situation in which i have 6 flat tables in my repository which all have a common field called Location ID (which is a lookup flat to the Locations table).
    i am trying to build a page with a free-form text search iView on Table #1 (search field = Location ID).  when I execute the search, the result set for Table #1 is properly updated, but how do I also get Result Set iViews for Tables #2-6 to also react to the event from Text Search for Table #1 so that they are updated?
    i don't want to have to build 6 different text search iViews (one for each table).  i just want to use ONE text search iView for all the different result set tables.  but, in the documentation and iView properties, the text search iView doesn't have any eventing.
    if you have any suggestions, please help.
    many thanks in advance,
    mm

    hello Donna,
    that should not be a problem, since you are detailw with result sets and detail iviews because custom eventing can be defined for those iviews.
    Yes, it says "no records" found because an active search and record selection havent' been performed for it (only your main table does).
    So, yes, define a custom event, and pass the appropriate parameters and you should be fine.
    Creating a custom event between a Result Set iView and an Item Details iView is easy and works. I have done it.
    See page 35 of the Portal Content Development Guide for a step-by-step example, which is what I used.
    For my particular situation, the problem I'm having is that I want the Search Text iView's event (i.e., when the Submit button is pressed) to be published to multiple iViews, all with different tables.  Those tables all share some common fields, which is what the Search iView has, so I'd like to pass the search critera to all of the iViews.
    -mm

Maybe you are looking for

  • Scanning multiple pages in one file - Deskjet 1510

    How to scan multiple pages and put them all in one pdf file? Currently, system is letting me scan one page and makes it one separate file, whereas I need to put them all in one single PDF file. Please assist. This question was solved. View Solution.

  • Re: Error while Execute External Operating System Command using T.code SM49

    Dear Experts, I Have uploaded one .exe file in the application server (eg: sum.exe) and created the OS command in SM69 transaction . And maintained the application server path in the 'operating system command' field in SM69 t.code. Our SAP system, op

  • Internal Order Release/Cancel Release/...

    Dear All, I have several questions regarding Internal Order (Order type - 0401) release/cancel release options. In order to make IO "usable" After creation I select Release option and then assign the budget to the order. When the order is no longer n

  • How can I use MapQuest API in Adobe Flash CC?

    Hi all, Since Google Maps API will be deprecated in 3 months I'm trying to use MapQuest instead. (MapQuest Developer Network: Map APIs, SDKs and Web Services - MapQuest Developer Network) But I can't import the component MQFlashMapsAPI_7.1.5_MQ_MOBIL

  • Import Image from scanner to database Direct ..

    can any Colleagues help me .. how can i Import Image From Scanner directly if anyone can descuss code and how can i do that thank for all Colleagues .......