Using OID's scema base tables fofr querying

Is it possible to use the underlying tables of OID's schema in you pL/sql code.One way of doing that is through dbms_ldap package.but in my case i dont want to connect to OID but i want to use the base tables in which the OID stores the data. we tried doing such an excersice but cud not get success. the only option we were left with was like creating our own tables having similar structure as that of OID's and then creating views on them.these views were used instead of dbms_ldap package.

Edited by: user11244575 on Oct 26, 2012 12:34 PM
Edited by: user11244575 on Oct 26, 2012 12:34 PM

Similar Messages

  • Use multiple partitions on a table in query

    Hi All,
    Overview:-
    I have a table - TRACK which is partitioned on weekly basis. Im using this table in one of my SQL queries in which I require to find a monthly count of some column data. The query looks like:-
    Select  count(*)
    from Barcode B
    inner join Track partition P(99) T
        on B.item_barcode = T.item_barcode
    where B.create_date between 20120202 and 20120209;In the above query I am fetching the count for one week using the Partitions created on that table during that week.
    Desired output:-
    I want to fetch data between 01-Feb and 01-Mar and use the rest of the partitions for that table during the duration in the above query. The weekly partitions currently present for Track table are -
    P(99) - 20120202
    P(100) - 20120209
    P(101) - 20120216
    P(102) - 20120223
    P(103) - 20120301
    My question is that above Ive used one partition successfully, now how can I use the other 4 partitions in the same query if I am finding the count for one month (i.e. from 201201 to 20120301) ?
    Environment:-
    Oracle version - Oracle 10g R2 (10.2.0.4)
    Operating System - AIX version 5
    Thanks.
    Edited by: Sandyboy036 on Mar 12, 2012 10:47 AM

    I'm with damorgan on this one, though I was lazy and only read it twice.
    You've got a mix of everything in this one and none of it is correct.
    1. If B.create_date is VARCHAR2 this is the wrong way to store dates.
    2. All Track partitions are needed for one month if you only have the 5 partitions you listed so there is no point in mentioning any of them by name. So the answer to 'how can I use the other 4 partitions' is - don't; Oracle will use them anyway.
    3. BETWEEN 01_Feb and 01-Mar - be aware that the BETWEEN operator includes both endpoints so if you actually used it in your query the data would include March 1.

  • Use of CDHDR and CDPOS Table in Query

    Hi all,
    I am having requirement where i need to fetch the data from the CDHDR and CDPOS by passing the release indicator from EKKO.
    I would like to know whether the performance will b the issue with this as the CDHDR and CDPOS are the tables which consist of Huge data.
    Pls let me know what will b the impact on performance and other things..
    Regards
    KK

    Hi,
    Pls chk this links, might be helpful;
    https://forums.sdn.sap.com/click.jspa?searchID=5749799&messageID=1456945
    Re: Delta - Records changed directly in table
    Generic delta queue for CDHDR
    LBWE, delta extraction without BW
    http://www.sap123.com/showthread.php?t=47
    Regards
    CSM Reddy

  • Indexed views using indexes on base table

    Hi all,
    CREATE VIEW Sales.vOrders
    WITH SCHEMABINDING
    AS
    SELECT SUM(UnitPrice*OrderQty*(1.00-UnitPriceDiscount)) AS Revenue,
    OrderDate, ProductID, COUNT_BIG(*) AS COUNT
    FROM Sales.SalesOrderDetail AS od, Sales.SalesOrderHeader AS o
    WHERE od.SalesOrderID = o.SalesOrderID
    GROUP BY OrderDate, ProductID;
    GO
    --Create an index on the view.
    CREATE UNIQUE CLUSTERED INDEX IDX_V1
    ON Sales.vOrders (OrderDate, ProductID);
    GO
    --This query can use the indexed view even though the view is
    --not specified in the FROM clause.
    SELECT SUM(UnitPrice*OrderQty*(1.00-UnitPriceDiscount)) AS Rev,
    OrderDate, ProductID
    FROM Sales.SalesOrderDetail AS od
    JOIN Sales.SalesOrderHeader AS o ON od.SalesOrderID=o.SalesOrderID
    AND ProductID BETWEEN 700 and 800
    AND OrderDate >= CONVERT(datetime,'05/01/2002',101)
    GROUP BY OrderDate, ProductID
    ORDER BY Rev DESC;
    In the above code block, Sales.SalesOrderDetail and Sales.SalesOrderHeader are base tables.
    Say suppose there are some indexes on some of the columns of these base tables. Are these indexes used when we write a query in which indexed view is mentioned
    in the from clause?
    Thanks, Srikar

    SO far as its a indexed view it wont use the indexes on base tables when you use it in a query as indexed view is persisted and exists as a physical object. SO it doent require definition to be substituted and data to be retrieved from the base objects.
    The indexes will come handy while populating the indexed view.
    Please Mark This As Answer if it solved your issue
    Please Vote This As Helpful if it helps to solve your issue
    Visakh
    My Wiki User Page
    My MSDN Page
    My Personal Blog
    My Facebook Page

  • API to update oracle base table in oracle apps

    Hi,
    What is the API used to update a base table in oracle contracts?
    Please suggest.

    If you are on 11i, please check irep.oracle.com
    It lists all APIs available.
    IREP - Oracle Integration Repository: The Tool To Find Which API Is Supported and How To Use It ... (Doc ID 554986.1)
    For R12, see
    Oracle Integration Repository Documentation Resources Release 12 (Doc ID 396116.1)
    Note: 462586.1 - Where are the Oracle® Release 12 (R12) API Reference Guide?
    https://metalink.oracle.com/metalink/plsql/ml2_documents.showDocument?p_database_id=NOT&p_id=462586.1
    Note: 458225.1 - Release 12 Integration Repository
    https://metalink.oracle.com/metalink/plsql/ml2_documents.showDocument?p_database_id=NOT&p_id=458225.1
    Hope this helps,
    Sandeep Gandhi

  • In 10g  ( 10.1.4.3)OID, what are the base tables

    Hi ,I need to clean the users and groups from the OID manually ( i have deleted them using bulkload but oid tree is inconsistent stage)
    so now i have to clean them from the base tables,
    anyone faced this situation before, appreciate your help.

    Check the ORACLE_HOME/ldap/log directory and the contents of oidmon.log and oidldapd01.log
    I found a similar error after the 10.1.4.3 upgrade and needed to rerun the root.sh script.
    It is helpful to shut everything down, cleanout the log files and file up OPMN (start) and the OID (using startproc).
    Good luck!

  • Index not using the base table

    Hi,
    In which scenario, a query will only use the index and not the base table. Please give me some example.
    Thanks,
    Santhosh
    Edited by: Santhosh on Oct 23, 2012 2:45 AM

    Chancal,
    not always,
    SQL> desc temp;
    Name                                                                                                      Null?    Type
    EMPNO                                                                                                              NUMBER(4)
    ENAME                                                                                                              VARCHAR2(10)
    JOB                                                                                                                VARCHAR2(9)
    MGR                                                                                                                NUMBER(4)
    HIREDATE                                                                                                           DATE
    SAL                                                                                                                NUMBER(7,2)
    COMM                                                                                                               NUMBER(7,2)
    DEPTNO                                                                                                             NUMBER(2)
    SQL> select empno from temp;
         EMPNO
          7369
          7499
          7521
          7566
          7654
          7698
          7782
          7788
          7839
          7844
          7876
          7900
          7902
          7934
          1057
    15 rows selected.
    SQL> select * from table(dbms_xplan.display_cursor);
    PLAN_TABLE_OUTPUT
    SQL_ID  3qt0w20pqj162, child number 0
    select empno from temp
    Plan hash value: 3800668828
    | Id  | Operation         | Name | Rows  | Bytes | Cost (%CPU)| Time     |
    |   0 | SELECT STATEMENT  |      |       |       |     2 (100)|          |
    |   1 |  TABLE ACCESS FULL| TEMP |    15 |    60 |     2   (0)| 00:00:01 |
    13 rows selected.
    SQL> alter table temp modify(empno not null);
    Table altered.
    SQL> select empno from temp;
         EMPNO
          1057
          7369
          7499
          7521
          7566
          7654
          7698
          7782
          7788
          7839
          7844
          7876
          7900
          7902
          7934
    15 rows selected.
    SQL> select * from table(dbms_xplan.display_cursor);
    PLAN_TABLE_OUTPUT
    SQL_ID  3qt0w20pqj162, child number 0
    select empno from temp
    Plan hash value: 472861760
    | Id  | Operation        | Name     | Rows  | Bytes | Cost (%CPU)| Time     |
    |   0 | SELECT STATEMENT |          |       |       |     1 (100)|          |
    |   1 |  INDEX FULL SCAN | IDX_TEMP |    15 |    60 |     1   (0)| 00:00:01 |
    13 rows selected.

  • Required to create a script for base table update using XMLSTORE package.

    Hi can anybody provide me some help full suggestion on how to update base table using XMLSTORE package.
    I created a simple script for Employee table and can able to do the basic operation like Insert and update on the table.
    Query is as follow's
    DECLARE
    insCtx DBMS_XMLSTORE.ctxType;
    rows NUMBER;
    xmlDoc CLOB :=
    '<ROWSET>
    <ROW num="1">
    <EMPLOYEE_ID>922</EMPLOYEE_ID>
    <SALARY>1801</SALARY>
    <HIRE_DATE>17-DEC-2007</HIRE_DATE>
    <JOB_ID>ST_CLERK</JOB_ID>
    <EMAIL>RAUSSJACK</EMAIL>
    <LAST_NAME>JACK</LAST_NAME>
    <DEPARTMENT_ID>20</DEPARTMENT_ID>
    </ROW>
    <ROW>
    <EMPLOYEE_ID>923</EMPLOYEE_ID>
    <SALARY>2001</SALARY>
    <HIRE_DATE>31-DEC-2005</HIRE_DATE>
    <JOB_ID>ST_CLERK</JOB_ID>
    <EMAIL>PATHAK</EMAIL>
    <LAST_NAME>PRATIK</LAST_NAME>
    <DEPARTMENT_ID>20</DEPARTMENT_ID>
    </ROW>
    </ROWSET>';
    BEGIN
    insCtx := DBMS_XMLSTORE.newContext('EMPLOYEES'); -- Get saved context
    DBMS_XMLSTORE.clearUpdateColumnList(insCtx); -- Clear the update settings
    -- Set the columns to be updated as a list of values
    DBMS_XMLSTORE.setUpdateColumn(insCtx, 'EMPLOYEE_ID');
    DBMS_XMLSTORE.setUpdateColumn(insCtx, 'SALARY');
    DBMS_XMLSTORE.setUpdateColumn(insCtx, 'HIRE_DATE');
    DBMS_XMLSTORE.setUpdateColumn(insCtx, 'JOB_ID');
    DBMS_XMLSTORE.setUpdateColumn(insCtx, 'EMAIL');
    DBMS_XMLSTORE.setUpdateColumn(insCtx, 'LAST_NAME');
    DBMS_XMLSTORE.setUpdateColumn(insCtx, 'DEPARTMENT_ID');
    -- Insert the doc.
    rows := DBMS_XMLSTORE.insertXML(insCtx, xmlDoc);
    --COMMIT;
    DBMS_OUTPUT.put_line(rows || ' rows inserted.');
    -- Close the context
    DBMS_XMLSTORE.closeContext(insCtx);
    END;
    SELECT employee_id, LAST_name FROM employees WHERE employee_id = 114;
    DECLARE
    updCtx DBMS_XMLSTORE.ctxType;
    rows NUMBER;
    xmlDoc CLOB :=
    '<ROWSET>
    <ROW>
    <EMPLOYEE_ID>114</EMPLOYEE_ID>
    <LAST_NAME>PRABHU</LAST_NAME>
    </ROW>
    </ROWSET>';
    BEGIN
    updCtx := DBMS_XMLSTORE.newContext('EMPLOYEES'); -- get the context
    DBMS_XMLSTORE.clearUpdateColumnList(updCtx); -- clear update settings
    -- Specify that column employee_id is a "key" to identify the row to update.
    DBMS_XMLSTORE.setKeyColumn(updCtx, 'EMPLOYEE_ID');
    rows := DBMS_XMLSTORE.updateXML(updCtx, xmlDoc); -- update the table
    DBMS_XMLSTORE.closeContext(updCtx); -- close the context
    commit;
    END;
    Nowi want little modification on this above query like as i am passing static XML tags and i want it to pick the dynamic XML from web and use the XMLSTORE for the update.
    and also for complex XML having 2-3 levels how this query needs to be changed.As i am new to this Oracle utillity any help from xepert will be a great help for me.
    Thanks

    Nowi want little modification on this above query like as i am passing static XML tags and i want it to pick the dynamic XML from webFrom a Web Service?
    You'll need UTL_HTTP or HttpUriType interface to send the request and receive the XML response.
    Search in the forum, there are already a lot of useful examples available.
    and also for complex XML having 2-3 levels how this query needs to be changed.DBMS_XMLStore is OK for readily processing a canonical XML format (/ROWSET/ROW/COLUMN structure or alike).
    However, if you have to deal with a more complex structure, you either have to :
    - use a target object table that matches the XML structure
    - preprocess the input document using XSLT to transform it to canonical format
    That's why DBMS_XMLStore is not appropriate for multilevel documents, especially if they contain nested repeating groups.
    In this case, XMLTable is a more flexible way of parsing the XML and process it relationally at the same time.
    Depending on the size of the document, performance may be improved with schema-based object-relational storage.
    For more help, please post a new thread in the {forum:id=34} forum, with the following information :
    - database version (select * from v$version)
    - a sample XML document (the complex one)
    - DDL of your target table
    - mapping between XML elements and columns (ie which tag goes to which column?)
    - an XML schema (if you have one)

  • Query on Non-base-table column in form

    Hi,
    Does anyone have an example of code to allow users to query on non-base-table column from forms? For example, a personnel form displays a persons' name and department name. The form is based on PERSON table, which contains the department id, not the name. The form uses post-query to display the department name. When in query mode, the user wants to enter department name, and display the people in the department (still using this form, which is based on PERSON table.
    Thanks!

    Try this:
    For data block person set these properties as follows:
    1.Set Query Data Source Name = "person , departments"
    2.Set DML data target name = "person"
    3.Set Where Clause to join i.e. condition "person.dno = departments.dno"
    For filed department name set these properties as follows:
    1.Data base item = "Yes"
    2.Column Name = "departments.dname"
    3.Query Only = "Yes"
    4.Insert Allowed = "No"
    5.Update Allowed= "No"
    6.Keyboard Navigable = "No"
    If you face ambiguous column name check for the same filed name exist on both tables and set column name for this filed to person.filed_name
    Regards
    null

  • Using case when statement in the select query to create physical table

    Hello,
    I have a requirement where in I have to execute a case when statement with a session variable while creating a physical table using a select query. let me explain with an example.
    I have a physical table based on a select table with one column.
    SELECT 'VALUEOF(NQ_SESSION.NAME_PARAMETER)' AS NAME_PARAMETER FROM DUAL. Let me call this table as the NAME_PARAMETER table.
    I also have a customer table.
    In my dashboard that has two pages, Page 1 contains a table with the customer table with column navigation to my second dashboard page.
    In my second dashboard page I created a dashboard report based on NAME_PARAMETER table and a prompt based on customer table that sets the NAME_ PARAMETER request variable.
    EXECUTION
    When i click on a particular customer, the prompt sets the variable NAME_PARAMETER and the NAME_PARAMETER table shows the appropriate customer.
    everything works as expected. YE!!
    Now i created another table called NAME_PARAMETER1 with a little modification to the earlier table. the query is as follows.
    SELECT CASE WHEN 'VALUEOF(NQ_SESSION.NAME_PARAMETER)'='Customer 1' THEN 'TEST_MART1' ELSE TEST_MART2' END AS NAME_PARAMETER
    FROM DUAL
    Now I pull in this table into the second dashboard page along with the NAME_PARAMETER table report.
    surprisingly, NAME_PARAMETER table report executes as is, but the other report based on the NAME_PARAMETER1 table fails with the following error.
    Error Codes: OPR4ONWY:U9IM8TAC:OI2DL65P
    State: HY000. Code: 10058. [NQODBC] [SQL_STATE: HY000] [nQSError: 10058] A general error has occurred. [nQSError: 16001] ODBC error state: S1000 code: 1756 message: [Oracle][ODBC][Ora]ORA-01756: quoted string not properly terminated. [nQSError: 16014] SQL statement preparation failed. (HY000)
    SQL Issued: SET VARIABLE NAME_PARAMETER='Novartis';SELECT NAME_PARAMETER.NAME_PARAMETER saw_0 FROM POC_ONE_DOT_TWO ORDER BY saw_0
    If anyone has any explanation to this error and how we can achieve the same, please help.
    Thanks.

    Hello,
    Updates :) sorry.. the error was a stupid one.. I resolved and I got stuck at my next step.
    I am creating a physical table using a select query. But I am trying to obtain the name of the table dynamically.
    Here is what I am trying to do. the select query of the physical table is as follows.
    SELECT CUSTOMER_ID AS CUSTOMER_ID, CUSTOMER_NAME AS CUSTOMER_NAME FROM 'VALUEOF(NQ_SESSION.SCHEMA_NAME)'.CUSTOMER.
    The idea behind this is to obtain the data from the same table from different schemas dynamically based on what a session variable. Please let me know if there is a way to achieve this, if not please let me know if this can be achieved in any other method in OBIEE.
    Thanks.

  • Use of base table concept in form developer

    can i get any white paper on use of base table concept in form developer.

    have a look at the quick tours in the online help they will show you how to do it.

  • Lookup-table and query-database do not use global transaction

    Hi,
    following problem:
    DbAdapter inserts data into DB (i.e. an invoice).
    Process takes part in global transaction.
    After the insert there is a transformation which uses query-database and / or lookup-table.
    It seems these XPath / XSLT functions are NOT taking part in the transaction and so we can not access information from the current db transaction.
    I know workarounds like using DbAdapter for every query needed, etc. but this will cost a lot of time to change.
    Is there any way to share transaction in both DbAdapter insert AND lookup-table and query-database?
    Thanks, Best Regards,
    Martin

    One dba contacted me and made this statement:
    Import & export utilities are not independent from characterset. All
    user data in text related datatypes is exported using the character set
    of the source database. If the character sets of the source and target
    databases do not match a single conversion is performed.So far, that does not appear to be correct.
    nls_characterset = AL32UTF8
    nls_nchar_characterset = UTF8
    Running on Windows.
    EXP produces a backup in WE8MSWIN1252.
    I found that if I change the setting of the NLS_LANG registry setting for my oracle home, the exp utility exports to that character set.
    I changed the nls_lang
    from AMERICAN_AMERICA.WE8MSWIN1252
    to AMERICAN_AMERICA.UTF8
    Unfortunately , the export isn't working right, although it did change character sets.
    I get a warning on a possible character set conversion issue from AL32UTF8 to UTF8.
    Plus, I get an EXP_00056 Oracle error 932 encountered
    ORA-00932: inconsistent datatypes: expected BLOB, CLOB, get CHAR.
    EXP-00000: export terminated unsuccessfully.
    The schema I'm exporting with has exactly one procedure in it. Nothing else.
    I guess getting a new error message is progress. :)
    Still can't store multi-lingual characters in data tables.

  • Query to find the Base tables of views

    Hi,
    Can you pl let me know the query to find the base tables on which the view is based.I looked into views like ci_view_definitions but i could not find them.
    Thanks for your help
    thanx,
    Suji.

    select vw.name viewname, nvl( tabdef.name, vwdef.name) "based on"
    from   ci_view_definitions vw
    ,      i$sdd_vwtab
    ,      ci_view_definitions vwdef
    ,      ci_table_definitions tabdef
    where  view_ref = vw.id
    and    table_ref = tabdef.id (+)
    and    table_ref = vwdef.id (+)

  • Using DAC for implementation of two change capture views on same base table

    Hello
    We have a need to create 2 views (V_INS_CLAIM & V1_INS_CLAIM) on a single table (S_INS_CLAIM) using DAC & Image tables.
    The V_INS_CLAIM will be used to load ODS on a hourly basis and
    The V1_INS_CLAIM will be used to load DataMart on a daily basis.
    For this purpose, we propose using the following approach:
    1) Create 2 separate containers - one for ODS and one for Datamart.
    2) Use a separate image table suffix (for the same table) on each container e.g.
    - Use image suffix 51 on S_INS_CLAIM for the ODS container (will result in image tables having suffix 51)
    - Use image suffix 61 on S_INS_CLAIM for the Datamart container (will result in image tables having suffix 61)
    3) In the ODS container, the change capture process would create a view V_INS_CLAIM using
    the base table S_INS_CLAIM and the I/R/D tables using image suffix 51
    For this folder the 'Drop and Create Change Capture Views Always' flag will be set to True
    All views for this container will be created with the prefix "V_"
    4) For the Datamart container, we propose to set the flag 'Drop and Create Change Capture Views Always' to False.
    This would ensure that DAC never drops/creates the view (assuming that the view was already created by the ODS container)
    For creating the change capture views, we propose to create the views using sql procedures.
    All views for this container will be created with the prefix "V1_"
    The above procedure would ensure that we have distinct views created for each target (ODS & Datamart), which are refreshed at different intervals.
    Alternatively, instead of creating 2 views with different names in the SIEBEL schema,
    we could create 2 schemas - one for ODS and the other for Datamart and create the change capture
    views separately in each schema (using separate I/R/D image tables - as mentioned above).
    Please let me know which of the above 2 approaches would work and supported by DAC and which would be the better option ?
    Thanks

    1.) Wrong forum. Go here: Business Intelligence Applications
    2.) Soft delete or hard delete? Sound to me like you want to get rid of teh records. I.e. deleting history.
    3.) Normal upsert mapping swon't do, you'll need delete mappings (depending on #2)

  • ORA-01776: cannot modify more than one base table through a join view

    I have created EO based on a database view than consists of two tables, and only one is updateable.
    When I try to update a row using EO, I got a following message: "ORA-01776-cannot modify more than one base table through a join view"
    In Forms, this issue is resolved by setting "Query Only" property of non-updateable items to "True".
    Is it possible to do something like that in ADF BC?
    Thanks

    Thanks for answer.
    When I set "updateable" property to "Never", that attribute is protected from any change.
    I'm sorry for incomplete usecase.
    I have set up a list of value on that attribute, because it is a lookup field for another table and I need to get an ID from that table.
    Basically, I need that attribute to be updateble for BC, but not for database.
    Edited by: MarioK on Oct 13, 2011 9:28 AM

Maybe you are looking for

  • List of unactioned Stock Transport Orders

    Hi, We want to see any report in SAP in which we can find list of Stock Transport Orders against which no action has been done... means no outbound delivery, no PGI and not any further action. Can anyone help us by providing any standard SAP Report i

  • Subform text flows off the page

    My subform text in preview doesn't page break. It flows right off the page. And I do have "Allow Page Breaks within Content" checked inside the Object tab. What's wrong?

  • File open - images display out of sequence

    Hi. I am new to this forum so please bear with me. I installed CS5 a few months back. All was okay except for things being a little slower than I hoped. The only thing I noticed right away was the top tool bar wasn't very clear which I thought most u

  • Files on desktop won't open

    I'm helping a friend with an iMac G5. (10.4...) Sometimes, after a couple days, the icons on the desktop suddenly won't open anymore (files, folders, external harddrives). Right-clicking (contextual menus) stops working on these icons, as well. Disk

  • I preorder a cd and one track didn't download

    I ordered the new Justin Timberlake album and didn't get track 2.