Suggested query (9i) for 3-d Geodetic point-in-poly?

Hi there,
Just getting started with Spatial. Have a SDO_POINT_TYPE layer in 8307 (Geodetic Lat/Lon/Height) 3-dim, indexed with 2-dim (Lat/Lon) and want to know what the best way is to perform point-in-polygon queries on this layer (e.g. basic web-mapping interface)? I recently tried SDO_GEOM.RELATE but it was extremely slow, and incorrect....certainly something I'm doing wrong.
Any help whatsoever is greatly appreciated.
Thanks in advance,
Michael

Thanks very much.
However, I the query doesn't seem to be giving me what I think it should. My index is two dimensions:
create index I_MONUMENT_SHAPE on MONUMENT_CATALOG (SHAPE)
INDEXTYPE IS MDSYS.SPATIAL_INDEX PARAMETERS('layer_gtype=POINT sdo_indx_dims=2');
"SDO_RELATE" query:
select mc.char_id as "ID",mc.shape as "Shape" from monument_catalog mc
where SDO_RELATE(mc.shape,MDSYS.SDO_GEOMETRY(2003,8307,null,MDSYS.SDO_ELEM_INFO_ARRAY(1,1003,1),
-- MDSYS.SDO_ORDINATE_ARRAY(-110,20,-110,30,-100,30,-100,20,-110,20)),'mask=inside querytype=WINDOW') = 'TRUE';
MDSYS.SDO_ORDINATE_ARRAY(-110,20,-110,30,-100,30,-100,20,-110,20)),'mask=anyinteract') = 'TRUE';
ID Shape(SDO_GTYPE, SDO_SRID, SDO_POINT(X, Y, Z), SDO_ELEM_INFO, SDO_ORDINATES)
BURR SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-110.066, 23.516, 535.02537), NULL, NULL)
ANCN SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-110.03, 23.739, 481.56558), NULL, NULL)
LPAZ SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-110.319, 24.139, -26.9092), NULL, NULL)
BLND SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-110.309, 24.326, -10.21309), NULL, NULL)
"vanilla sql" query:
select mc.char_id as "ID",mc.shape as "Shape" from monument_catalog mc
where mc.shape.SDO_POINT.X < -100
and mc.shape.SDO_POINT.X > -110
and mc.shape.SDO_POINT.Y < 30
and mc.shape.SDO_POINT.Y > 20;
ID Shape(SDO_GTYPE, SDO_SRID, SDO_POINT(X, Y, Z), SDO_ELEM_INFO, SDO_ORDINATES)
CEBO SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-103.161, 20.09, 2009.12022), NULL, NULL)
JARA SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-101.8, 21.264, 2016.36392), NULL, NULL)
UMON SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-103.453, 20.737, 1626.65695), NULL, NULL)
ineg SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-102.284, 21.856, 1888.67922), NULL, NULL)
AYUT SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-104.374, 20.188, 1648.7741), NULL, NULL)
CHAC SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-105.429, 20.383, 280.64762), NULL, NULL)
COSA SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-103.325, 20.293, 1730.68995), NULL, NULL)
GUAC SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-104.354, 20.501, 1581.31376), NULL, NULL)
MCAB SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-103.493, 21.092, 1682.41884), NULL, NULL)
SEBA SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-104.871, 20.699, 1973.90223), NULL, NULL)
ECER SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-109.81, 24.18, 89.31145), NULL, NULL)
EMIR SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-109.735, 23.366, 192.75321), NULL, NULL)
RIVE SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-109.532, 23.549, 40.95293), NULL, NULL)
LIM2 SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-103.528, 20.335, 1652.13807), NULL, NULL)
SAUZ SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-103.225, 20.885, 1699.7295), NULL, NULL)
7122 SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-106.459, 23.343, 27.9281), NULL, NULL)
3033 SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-109.086, 25.692, -30.58101), NULL, NULL)
7882 SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-109.864, 22.918, 115.09006), NULL, NULL)
LIMA SDO_GEOMETRY(3001, 8307, SDO_POINT_TYPE(-103.548, 20.37, 2112.2829), NULL, NULL)
Any idea why the SDO_RELATE query seems to be giving me stuff just ---outside--- my query window rather that stuff that lies inside?
Thanks,
Michael

Similar Messages

  • Query runs for ever - suggestions - ideas - tips

    Hello all,
    I have the following situation:
    1) Database 1: XE 10g Release 10.2.0.1.0 - Production
    2) Database 2: 10g Enterprise Edition Release 10.2.0.4.0 - 64bit Production
    3) Dblink from Database 1 pointing to Database 2
    4) Synonyms created withing Database 1, pointing to Database 2 packages and tables:
    - "mytable1" exists in Database 2 therefore a synonym "mytable1" is created in Database 1
    - "mytable2" exists in Database 2 therefore a synonym "mytable2" is created in Database 1
    - "mypackage" exists in Database 2 therefore a synonym "mypackage" is created in Database 1
    5) Of course select and execute rights are granted
    6) Query:
    SELECT field1
    FROM myshcema.mytable1
    WHERE field2 = myshcema.mypackage.myfunction ('PARAMVALUE'))
    AND EXISTS (SELECT 1 FROM myshcema.mytable2 WHERE field_in_tab2 = field_in_tab1)
    7) Problem.This query runs for ever
    8) Explain plan
    OPERATION - OBJECT_NAME - OPTIONS - COST
    SELECT STATEMENT - - - 17
    -> FILTER - - -
    -> -> FILTER - - - 3
    -> -> -> REMOTE - mytable1 - -
    -> -> REMOTE - mytable2 - - 1
    9) Now I get the value returned by the function and re-execute the previous query:
    - select myshcema.mypackage.myfunction ('PARAMVALUE')) from dual;
    - return value is *89787621*
    - re-executing the query:
    SELECT field1
    FROM myshcema.mytable1
    WHERE field2 = *89787621*
    AND EXISTS (SELECT 1 FROM myshcema.mytable2 WHERE field_in_tab2 = field_in_tab1)
    10) Explain plan
    OPERATION - OBJECT_NAME - OPTIONS - COST
    SELECT STATEMENT - - REMOTE - 3
    -> NESTED LOOPS - - SEMI - 3
    -> -> INDEX - MY_UK_NAME - RANGE SCAN - 3
    -> -> INDEX - MY_2ND_UK - UNIQUE SCAN - 0
    And the results are instantaneous
    Now my question: Can somebody direct me on whether a hint or something else will correct this situation? Due to restrictions that I cannot currently explain here, I am not able to change the code to first get the value and then execute the query.
    Thanks for helping
    G
    Edited by: G on May 17, 2011 9:07 AM
    Edited by: G on May 17, 2011 9:10 AM

    I would think the driving site hint woud be the frist thing I tried. If for some reason Oracle does not seem to be able to use the hint or if hints are heavily frowned on at your site then here is another approach to the problem.
    Code the query into a view and define the view on the remote database then issues a local query against the remote view.
    HTH -- Mark D Powell --

  • SAP QUERY report for vendor line items

    Hi
    I have created a SAP QUERY report for vendor line items with fields vendor no.,vendor name,amount,company code and period.But there is one line item i donot know from wher system is getting it picked with is not in that vedor account,when i compare with fbl1n.I checked the document number too...the same doc number is twice in my query report.One with correct amount and another with wrong one.How do i chk.Where did i go wrong in creating query.I used logical database KDF.
    Please advise.

    i chked...how do we get the amount displayed in query...it just displays amount no debit credit symbol... i have selected BSEG-DMBTR field but no -/+ sign,how is it done in query,please suggest.

  • Search suggestion not working for anonymous user in sharepoint 2013

    Hi ,
    Please help on this search suggestion not working for anonymous user in sharepoint 2013
    shaik

    You can create a search center site, and set the search center site to
    allow anonymous access.
    Also see this link - http://blog.mastykarz.nl/search-query-suggestions-anonymous-users-sharepoint-2013-mavention-query-suggestions/ 
     (As this is regarding a 3rd party tool, I suggest that you direct it to the  provider support.)
    Please 'propose as answer' if it helped you, also 'vote helpful' if you like this reply.

  • Where can we suggest new features for Yahoo Messenger and other RIM IM clients?

    I just downloaded the new version of Yahoo Messenger and I like the user interface. But every time a new version comes out, this application creates a less-complete history of contact behavior. Several versions ago, the contact's status showed up in the open conversation, along with the time stamp of when the status changed. This included Idle and Custom Status changes. That disappeared. In the last version, you could see the time the contact signed in or out last, and sometimes both. Now they're gone as soon as you close the conversation.
    The whole idea of having Yahoo up on the BlackBerry all the time is that you don't have to be staring at the screen all the time, that you should be able to take it out of your pocket and check out those events that occurred that didn't set off alarms. I'd like the whole contact history to be right there, for as long as I want to keep it active. How can I make this suggestion to RIM for the next version of Yahoo Messenger? Thanks.
    Message Edited by kstrouse on 07-10-2008 02:20 PM
    Solved!
    Go to Solution.

    This is a good place to share your thoughts and ideas. RIM could easily get these info as this community is build by RIM.
    tanzim                                                                                  
    If your query is resolved then please click on “Accept as Solution”
    Click on the LIKE on the bottom right if the post deserves credit

  • Spatial query (point in poly) problem

    Hi
    One of my users is trying to run the following query in SQL*Plus:
    CREATE TABLE erdpwip_join AS
    SELECT A.CSNGC, B.PARCELID
    FROM RLR.RLR87_SK B, ERDPWIPDATA A
    WHERE sdo_relate (a.geom, b.geom, 'mask=ANYINTERACT querytype=Window') = 'TRUE'
    He says it works on a small subset of the full dataset, but when he tries to run it on a larger selection of data it stops working. The full dataset has 1.6 million shapes and is held in an Oracle 9.2.0.5.0 database. It isn't clean data, unfortunately: I performed an sdo_geom.validate_layer_with_context on it and removed around 240 shapes with errors (mostly self-intersects), but when trying to access the dataset through ESRI's ArcSDE (version 8.3) a load_buffer error -2035 occurs, which I am informed is because there are other low-level self-intersects which Oracle's validation routine didn't pick up.
    There are two questions really: first, is the quality of the data (with these geometric errors) the reason for the user's point-in-polygon query not working on larger recordsets (e.g. about 400000 records), or is because of the volume of data?
    Secondly, is there any way that Oracle's validation routines will pick up these low-level self-intersects which were missed in the first pass? ESRI's support forum recommends running a query on the dataset which steps through so many records at a time until it finds an error - the full thread is at http://forums.esri.com/Thread.asp?c=2&f=1720&t=152985&mc=1.
    Any help would be appreciated.
    Thanks
    Sharon Evans

    Hi Sharon,
    What does "it stops working" mean? Error? Long running query?
    Assuming your data is now clean in spatial, I would try creating the table, then loading it with the query using the ordered hint. The number of geometries, while affecting run time, is certainly not more than spatial can handle.
    CREATE TABLE erdpwip_join AS
    SELECT A.CSNGC, B.PARCELID
    FROM RLR.RLR87_SK B, ERDPWIPDATA A
    WHERE rownum < 1;
    insert into erdpwip_join
    SELECT /*+ ordered */ A.CSNGC, B.PARCELID
    FROM RLR.RLR87_SK B, ERDPWIPDATA A
    WHERE sdo_relate (a.geom, b.geom, 'mask=ANYINTERACT querytype=Window') = 'TRUE';
    Regarding drawing in ESRI and tolerance/validation:
    In Oracle Spatial the tolerance is specified as the distance two points have to be apart to be considered different.
    I think for ESRI, points have to be greater than tolerance apart (not exactly tolerance apart, which is fine in spatial).
    So what you might want to try is kicking up the tolerance by some very small increment for the validation, remove or fix those invalid geometries, reset the tolerance back to the smaller value, and then try using ArcSDE again.
    I haven't tried this at all, so if you can let us know if this works we'll know this is probably a good general recommendation.

  • Editing the Query name for all reports in PRD.

    Dear All,
    I have created 25 reports using Query Designer.We have moved all the reports to BI Production. And Clients are using these reports using the Tool Bex Analyser.
    Every time they are navigating through open Query -> Info Areas -> Data targets and Query.
    Instead of going this way, is there any other way to Open a query easily.
    And they wants to modify the Report name and the Technical name for all the reports. Can we able to edit the Query name for all reports, or do i need to go for SAVE AS for all querys.
    Pls Suggest.
    Thanks,
    Ram

    Hi Ram,
    1. For the first question; if it user specific query then ask the users to save them at the FAVORITES so that there is no need to go to the dataprovider specific.
    Or they can create the reports as favorites user menu screen of that particular user.
    2. In order to change the technical name and description of the queries goto RSZC t-code> give the source and target infoprovider as same> select queries>click on the reports>click on transfer selections-->
    Then you get a screen to change the description and technical name.
    But this is pertained to Infoprovider level.
    You can see all the reports on the infoprovider (cube/ods).
    Hope you understood.
    Regards,
    Ravi Kanth

  • Publishing server doesn't work - error 'The request URL doesn't contain the query string for the client OS'

    Hi,
    I'm trying to setup an App-V environment in my lab.
    I've used the App-V 5.0 Trial guide to help me configure all necessary components.
    I'm able to install everything without error.
    when come time to publish an app, it simply doesn't show up on my client.
    after looking at events on the client and server, I found that the Publishing server is returning under Admin the following message.
    'The request URL doesn't contain the query string for the client OS'
    My setup is pretty simple.
    App-V Server managament and Publishing on the same box
    App-V database on my SQL server.
    I'm able to see the publishing "webpage" by using http:://localhost:889.
    It only display this :
    -<Publishing Protocol="1.0"
    <Packages />
    </Publishing>
    I've published one app from the management console.
    any idea what could mean this error?
    thanks

    Hi,
    thanks for the link.
    I've validated the suggested debug steps. It seems that the problem is with my Publish server again.
    I've looked in the web.config file. It seems to be missing some parts compare to the example provided.
    Again, I've published an application from the management console. Management and Publishing are running on the same box, while SQL is remote.
    Here's the web.config
    <?xml version="1.0" ?>
    - <configuration>
    - <system.web>
    <compilation debug="false" targetFramework="4.0" />
    <machineKey validationKey="AutoGenerate,IsolateApps" decryptionKey="AutoGenerate,IsolateApps" />
    - <authentication>
    - <!-- We don't support form authentication, but this will supress x-ray security warning
    -->
    <forms requireSSL="true" />
    </authentication>
    </system.web>
    - <system.webServer>
    - <modules runAllManagedModulesForAllRequests="true">
    <add name="UrlRoutingModule" type="System.Web.Routing.UrlRoutingModule, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
    </modules>
    - <security>
    - <requestFiltering>
    - <verbs>
    <remove verb="GET" />
    <add verb="GET" allowed="true" />
    </verbs>
    </requestFiltering>
    </security>
    </system.webServer>
    - <system.serviceModel>
    <serviceHostingEnvironment aspNetCompatibilityEnabled="true" multipleSiteBindingsEnabled="true" />
    + <behaviors>
    - <serviceBehaviors>
    - <behavior name="">
    <serviceAuthorization impersonateCallerForAllOperations="true" />
    <serviceMetadata httpGetEnabled="false" httpsGetEnabled="false" />
    </behavior>
    </serviceBehaviors>
    </behaviors>
    - <bindings>
    - <webHttpBinding>
    - <binding name="SecureBinding">
    - <security mode="Transport">
    <transport clientCredentialType="Windows" />
    </security>
    </binding>
    <binding name="UnsecureBinding" />
    </webHttpBinding>
    </bindings>
    - <protocolMapping>
    <add scheme="http" binding="webHttpBinding" bindingConfiguration="UnsecureBinding" />
    <add scheme="https" binding="webHttpBinding" bindingConfiguration="SecureBinding" />
    </protocolMapping>
    - <standardEndpoints>
    - <webHttpEndpoint>
    - <!--
    Configure the WCF REST service base address via the global.asax.cs file and the default endpoint
    via the attributes on the <standardEndpoint> element below
    -->
    <standardEndpoint name="" helpEnabled="true" automaticFormatSelectionEnabled="true" />
    </webHttpEndpoint>
    </standardEndpoints>
    </system.serviceModel>
    </configuration>

  • Problem when querying OLAP for Value based hierarchy

    Hi I have problem when querying OLAP for value based hierarchy , for level based dimension it work fine
    the strange part is if I only put one value, it will work perfectly
    for example if I put only 1 value for that value base hierarchy like CF_HIER::426362, then it will get the correct value for that id 426362
    but if I put multiple value to the list
    CF_HIER::426362
    CF_HIER::424470
    CF_HIER::429073
    CF_HIER::424230
    then only some value will come out correctly, some of them will be 0, I wonder why because if I query using each value, then it show correct value
    for multiple value usually only the top in hirarchy give correct value, but the leaf will give 0, but if I query only the leaf, the leaf will give correct value
    this problem only happen for my value based hierarchy, for the level based hierarchy it work fine both for each value or multiple value in the list
    this is the code how I guery
    ////the "elementIdList" is where the value is (CF_HIER::426362,CF_HIER::424470,CF_HIER::429073,CF_HIER::424230), if I only put single value in this list the query work fine, but if I put multiple value then some value give correct result, some will give 0
    String[] elementIdArr = new String[elementIdList.size()];
              int i = 0;
              for (Long elementId: elementIdList) {
                   String elementIdStr ="";
                   if (hierarchy instanceof MdmLevelHierarchy)
                        elementIdStr = hierarchy.getName()+dimension.getValueSeparationString()+
                                            level.getName()+dimension.getValueSeparationString()+
                                            level.getName()+"_"+elementId;
                   else
                        elementIdStr = hierarchy.getName()+dimension.getValueSeparationString()+
                                            elementId;
                   elementIdArr[i++] = elementIdStr;
              Source myList = dp.createListSource(elementIdArr);
              result = hierarchy.getSource().selectValues(myList);
         Source joinedSource = measure.getSource();
              joinedSource = joinedSource.join(result );
    is there any suggestion where I'm doing wrong?or is it different between querying value based hier with level based hier?
    thanks

    Hi I have problem when querying OLAP for value based hierarchy , for level based dimension it work fine
    the strange part is if I only put one value, it will work perfectly
    for example if I put only 1 value for that value base hierarchy like CF_HIER::426362, then it will get the correct value for that id 426362
    but if I put multiple value to the list
    CF_HIER::426362
    CF_HIER::424470
    CF_HIER::429073
    CF_HIER::424230
    then only some value will come out correctly, some of them will be 0, I wonder why because if I query using each value, then it show correct value
    for multiple value usually only the top in hirarchy give correct value, but the leaf will give 0, but if I query only the leaf, the leaf will give correct value
    this problem only happen for my value based hierarchy, for the level based hierarchy it work fine both for each value or multiple value in the list
    this is the code how I guery
    ////the "elementIdList" is where the value is (CF_HIER::426362,CF_HIER::424470,CF_HIER::429073,CF_HIER::424230), if I only put single value in this list the query work fine, but if I put multiple value then some value give correct result, some will give 0
    String[] elementIdArr = new String[elementIdList.size()];
              int i = 0;
              for (Long elementId: elementIdList) {
                   String elementIdStr ="";
                   if (hierarchy instanceof MdmLevelHierarchy)
                        elementIdStr = hierarchy.getName()+dimension.getValueSeparationString()+
                                            level.getName()+dimension.getValueSeparationString()+
                                            level.getName()+"_"+elementId;
                   else
                        elementIdStr = hierarchy.getName()+dimension.getValueSeparationString()+
                                            elementId;
                   elementIdArr[i++] = elementIdStr;
              Source myList = dp.createListSource(elementIdArr);
              result = hierarchy.getSource().selectValues(myList);
         Source joinedSource = measure.getSource();
              joinedSource = joinedSource.join(result );
    is there any suggestion where I'm doing wrong?or is it different between querying value based hier with level based hier?
    thanks

  • Query language for XML documents

    Which is a better (efficiency in terms of memory management) query language for interacting with XML documents.The query language shouls support 'insert', 'delete', 'update' and 'select' commands. How fast is database as compared to XML ( database being replaced by XML) when only 'insert' n 'select' commands are issued?

    Hi,
    I suggest you use the Sunopsis JDBC for XML driver that will let you perform all kind of SQL statements on your XML files. It is a type 4 driver so it's very use to use. You may have more information and download it here:
    http://www.sunopsis.com/corporate/us/products/jdbcforxml/
    Hope that will help
    Simo Fernandez

  • Point in Poly query?

    How do I perform a simple point in poly query with spatial?
    If I have a set of coordinates (-86.524442 39.7748187) for which I want to know which polygon they fall inside of?
    Thanks in advance-M.

    A query like this should get what you're after :
    select county
    from counties c
    where sdo_relate(c.geom, mdsys.sdo_geometry(2001,
    null,
    mdsys.sdo_point_type(-86.524442,39.7748187,null),
    null, null),
    'mask=contains querytype=window') = 'TRUE'
    This will return "Hendricks" county which I believe is correct.
    The relevant parms for the mdsys.sdo_geometry object are the "2001" which specifies a point object and then the creation of the actual sdo_point_type itself. The third parm to this object is null as that is the Z access.
    The Oracle Spatial Users Guide is very useful and has lots of information and examples of this kind of thing.
    Steve

  • Point in poly tuning suggestions?

    I have a static table with 250 non-overlapping polygons. I wrote a function to accept a point and perform a point in poly calculation (sdo_relate) and do nearest neighbor if no poly contains the point. An application calls this function about 1.5 million times a day. The function performs pretty well (executes about 15 times per sec.) most of the time, but falls behind during peak application times. For both resource reasons and application reasons, I can not thread this out.
    Usually the application has other metadata that can narrow the list of potential polygons down to 2 or 3. I tried including this into the function by adding "where column_3 in (1,54,...)" but saw no change in performance or execution plan for that matter. The sql in the function is inside and execute_immediate statement with bind params if that matters.
    The table and indexes have had stats run, and the sdo_tune.analyze_rtree reports that everything is good.
    This is on a 9.2.0.4 database on a compaq dl-360 (2-cpu) running RH Linux.
    Any tuning suggestions? It seems like I should be able to make it run faster driving off of the other column and only running sdo_relate against a couple of polys.

    Hi,
    sdo_relate always uses the spatial index, which in monolithic for the table - adding other attibutes won't limit the use of the index and relate.
    If you can narrow things down to one or two geometries, you might consider use of sdo_geom.relate with the one or two geometries you've narrowed things down to. It might be worth looking at.
    hope this helps - let us know.

  • Map Viewer Query Rewriting for Dynamic themes and  Materialized Views.

    Hi,
    I am usng a WMS request to render FOI points in my map.
    Internally query rewrite is happening in Mapviewer for this dynamic theme and my data points query is getting converted as
    select FROM
    ( select status, shape from MatView.MyTab where id = '3' )
    WHERE MDSYS.SDO_FILTER(shape, MDSYS.SDO_GEOMETRY(2003, 4283, NULL, MDSYS.SDO_ELEM_INFO_ARRAY(1, 1003, 3), MDSYS.SDO_ORDINATE_ARRAY(144.948120117188,-37.8162934802451,144.950866699219,-37.8141237016045)), 'querytype=WINDOW') = 'TRUE'
    here the rewritten query is not correct and is throwing exceptions in mapviewer log
    How can I make this query to be written correctly.
    (My orginal query before rewrite is: select status,shape from MatView.MyTab where id='3' )
    I am using a materialised view : MatView is a materialized view.
    When I used normal tables, the query is re written correctly.But for this materialized view this is happening.
    How can I correct the error?
    Is this has something to do with some Spatial Indexing in Materialised view or Query Rewriting for materialized view?
    Edited by: 841309 on Mar 10, 2011 11:04 PM

    Oops!
    The Materialized view was not accessible from the schema I tried :)
    And so when I gave permissions,it formed the correct query.
    So if permission is not there,map viewer will rewrite the query in a wrong way! New information.

  • Error while running a query-Input for variable 'Posting Period is invalid

    Hi All,
    NOTE: This error is only cropping up when I input 12 in the posting period variable selection. If I put in any other value from 1-11 I am not getting any errors. Any ideas why this might be happening?
    I am getting the following error when I try and run a query - "Input for variable 'Posting Period (Single entry, mandatory)' is invalid" - On further clicking on this error the message displayed is as follows -
    Diagnosis
    Variable Posting Period (Single Value Entry, Mandatory) is used as a lower limit (X) and an upper limit () in an interval selection. This limit has the value #.
    System Response
    Procedure
    Enter a different value for variable Posting Period (Single Value Entry, Mandatory). If the value of the other limit is determined by another variable, you can change its value also.
    Procedure for System Administration

    OK.
    Well, if the variable is not used in any interval selection, then I would say "something happened to it".
    I would make a copy of the query and run it to check if I get the same problem with period 12.
       -> If not, something is wrong in the original query (you can proceed as below, if changes to original are permitted).
    If so, then try removing the variable completely from the query and hardcode restriction to 12.
       -> If problem still persists, I would have to do some thinking.
    If problem is gone, then add the variable again. Check.
       -> If problem is back, then the variable "is sick". Only quick thing to do, is to build an identical variable and use that one.
    If problem also happens with the new variable, then it's time to share this experience with someone else and consider raising an OSS.
    Good luck!
    Jacob
    P.S: what fisc year variant are you using?
    Edited by: Jacob Jansen on Jan 25, 2010 8:36 PM

  • Is it too much to ask MS for a simple ad-hoc query tool for end users?

    Hello
    This is a general MS BI topic and not specific to Power Query, but I couldn't find a more suitable general forum for it.
    This posting is the result of the frustration I have with MS BI stack, whereby a simple ad-hoc drag and drop query tool to get the data in a table format (preferably from a relational
    data source) is missing, something that other big vendors have, such as SAP Business Objects Universe and the associated tools. The deprecated SSRS Report model and SMDL was the closest MS ever got to this functionality (although that had some limitations
    too), which unfortunately is dead now in favour of all sort of "Power" tools that basically can’t deliver the same functionality.
    The requirement is pretty simple: provide users with a tool that they can drag and drop fields from different entities in a data model without having to worry about entity relationships and
    apply necessary filters and get the data out in Excel or CSV, no fancy (or even simple) aggregation or formatting is required, and users should only see the rows they are authorized to see, i.e. row level security (RLS) of data.
    Let’s see what we have at our disposal from MS BI:
    From the modeling perspective, we have relational models in the database that support RLS with views, but obviously cannot maintain PK-FK relationships in the database model between views. Other
    models are .Net Entity Data model Framework model exposed as OData, and SSAS tabular, SSAS PowerPivot, SSAS multidimensional, which you can find a good comparison of their features here:
    http://www.sqlchick.com/entries/2012/3/4/decisions-powerpivot-ssas-tabular -or-ssas-multidimensional-m.html
    From the tools perspective we have:
    Power Query on top of a relational database (SQL Server): Can connect to relational databases easily, generated queries are optimal, detects relationships with entities, but only when entities
    are tables and have PK-FK relationships enforced in the database. So can’t detect relationships with views and hence can’t enforce RLS, so this is not an option unless users keep joining entities, which is not a desirable option either.
    Power Query on top of an OData: Works well except that queries generated for multiple entity expansion are terrible (look here for more details:
    http://social.technet.microsoft.com/Forums/en-US/7a8b8e52-d3a9-42af-bc52-9d5459c00529/odata-multilevel-expand-query-issue?forum=powerquery). In addition all filtering and projections are done at client side, so even if you want 1 row out of 1 million, all
    rows are brought over to Excel before filtered. Overall this results in unacceptable performance even for small sized data.
    Power Query on top of a tabular model: Doesn’t support that type of data source yet (http://social.technet.microsoft.com/Forums/en-US/ebcccb5e-7058-4046-917d-3d7fcf60cbdc/tabular-model-as-data-source-for-power-query?forum=powerquery).
    Even if it did, tabular models don’t support Many-to-Many relationships out of the box and not sure if there are plans to support tabular models in Direct Query mode in Power Query to take care of RLS.
    Excel on top of tabular models or multidimensional models: The tabular model should not be in Direct Query mode and you only get to use PivotTable to query the model. PivotTables are not famous
    for generating optimal MDX queries, so performance is not going to be acceptable if you are dealing with large dimensions, especially large junk and degenerate dimensions. You can use drilltrough to get details of a measure, but you have to specify the columns
    for a drilltrough action upfront, no flexibility for users to select what they want to see.
    PowerPivot on top of relational databases: The query designer cannot detect relationships between views, so users have to perform manual joins, not an option.
    PowerPivot on top of a multidimensional or tabular model: The query designer doesn’t generate optimal MDX queries by drag and drop. Especially there doesn’t seem to be a way to add related
    attributes of a dimension attribute to the query without cross joins which results in poor performance on large dimensions. Other issues found here
    http://sqlblog.com/blogs/marco_russo/archive/2010/08/24/using-ssas-2005-2008-as-powerpivot-data-source-query-designer.aspx. In addition the result set has ugly column names and issues with data types, such as interpreting numeric data types as Text, and
    there’s no straight forward way of getting the data from PowerPivot directly to Excel. The user either has to do a copy/paste (which doesn’t work on large datasets) or create a pivot table, bring the measure, and drillthrough the measure to get the details
    in table format.
    PowerPivot with OData: Treats every entity as a separate table to import, not suitable for our use case.
    Report Builder and SSRS on top of relational, multidimensional or tabular model: Given the query designer is the same as PowerPivot, it has similar issues. In addition, there are 4 more steps
    from designing a query to generating an Excel or CSV output, not an option.
    PowerView: Works against tabular and multidimensional models, but there’s no way of exporting data to Excel sheet. Besides the add-in is not available for Excel 2010.
    Good old MS-Access: Link to tables and views through ODBC, create relationships between entities and give each user a copy of that Access database to create their queries, and deal with the
    nightmares of updates to the model and distribution of new models to the users! Did I mention Access as an option?
    So there you go, 10 options, none of which can deal with a seemingly simple use case sufficiently. At the moment, the best among them appears to be option 6 against a heavily optimized OLAP
    cube, and perhaps #3 when/if Power Query support for tabular models in direct query mode arrives. Perhaps I am missing something very obvious, and would like someone to enlighten me here.
    Thanks
    MR

    Hi, as far as I can infer, that term means it's not loading any resources until needed, opposite of this...
    -bind_at_load
                     Sets a bit in the mach header of the resulting binary which tells dyld to bind all symbols                when the binary is loaded, rather than lazily.
    https://developer.apple.com/library/mac/documentation/Darwin/Reference/ManPages/ man1/ld.1.html
    Load resources lazily.
    You should never load a resource file until it is actually needed. Prefetching resource files may seem like a way to save time, but this practice actually slows down your app right away. In addition, if you end up not using the resource, loading it wastes memory for no good purpose.
    http://developer.apple.com/library/ios/#documentation/iphone/conceptual/iphoneos programmingguide/PerformanceTuning/PerformanceTuning.html
    And, higher OS versionsare even worse with Bonjour/mDNSResponder, but might see this...
    http://support.apple.com/kb/ht3789

Maybe you are looking for

  • Standard user cannot install apps

    I have setup a Mac Mini in my office for several people to use, with me as Admin and others as Standard account.  The problem is, when someone wants to install an app, they always get a prompt to input the Admin's username and password.   From my res

  • Different onMouseOver Event for each row of a report

    Hi all, See http://htmldb.oracle.com/pls/otn/f?p=41861:1 As you can see in the demo, all employees of a department are shown when you click the detail link for a department. This is done with the help of AJAX technologie to avoid the submit of the pa

  • Hp w1907 monitor

    will not stay awake.  as soon as it powers up it goes to sleep.

  • "Sort by site" is not working in the history bar

    The other "sort by" options in the history bar are working fine. Each time I change it, the list of websites gets re-sorted. Except for Sort by site, which isn't doing anything. Is there a fix for this problem?

  • GRN against short closed PO

    Hi, System is allowing to post the GRN against those POs which are already short closed...which is wrong. Can anybody plz suggest how to put ERROR Message in GRN while posting against short closed PO ??? Regards, Raghunath