Oracle BUG (CASE + remote tables + inline view)

Oracle 9.2.0.8
BUG: Oracle inserts NULL when we use CASE statement in the SELECT query and we join a remote table with inline view.
Script:
CREATE TABLE t1 (a number(19,4)OK.
SELECT (case when b = 1 then c else d end)
FROM t2@Remote LEFT JOIN
(SELECT a FROM t3@Remote) q ON (t2.a = q.a)123
456
789
3 rows selected.
INSERT INTO TABLE t1 (a)
SELECT (case when b = 1 then c else d end)
FROM t2@Remote LEFT JOIN
(SELECT a FROM t3@Remote) q ON (t2.a = q.a)3 rows inserted.
SELECT * FROM t1<null>
<null>
<null>
3 rows selected
Oracle inserts the correct values if I:
* replace the CASE with DECODE
* join with table not with an inline view
* join local tables
Someone with registration in the Metalink can post the bug.
Best regards, Beroetz

Oracle 9.2.0.8
BUG: Oracle inserts NULL when we use CASE statement in the SELECT query and we join a remote table with inline view.
Script:
CREATE TABLE t1 (a number(19,4)OK.
SELECT (case when b = 1 then c else d end)
FROM t2@Remote LEFT JOIN
(SELECT a FROM t3@Remote) q ON (t2.a = q.a)123
456
789
3 rows selected.
INSERT INTO TABLE t1 (a)
SELECT (case when b = 1 then c else d end)
FROM t2@Remote LEFT JOIN
(SELECT a FROM t3@Remote) q ON (t2.a = q.a)3 rows inserted.
SELECT * FROM t1<null>
<null>
<null>
3 rows selected
Oracle inserts the correct values if I:
* replace the CASE with DECODE
* join with table not with an inline view
* join local tables
Someone with registration in the Metalink can post the bug.
Best regards, Beroetz

Similar Messages

  • Oracle errors in a table or view

    Hi,
    Is there any oracle table or view with all the oracle error numbers and error messages
    from ORA-00000 till ORA-36804.
    Please let me know.
    Thanks in advance.
    Sreenath.

    There isn't a table, but you can create your own easily. This script displays them all but you could just as easily insert them into a table:
    DECLARE
       err_msg          varchar2(4000);
    BEGIN
    FOR err_num IN 0..36804 LOOP
       err_msg := SQLERRM(-err_num);
       if instr(err_msg, 'Message ' || err_num || ' not found;') = 0 then
          dbms_output.put_line(err_msg);
       end if;
    END LOOP;
    END;
    /Notice that this doesn't print errors that have no associated message.

  • Oracle Internet Expenses related tables and views

    In Oracle 11i when we go for internet expenses how to get the table and view details

    user12180635 wrote:
    Thanks for your reply. But didn't find any Schema or Tables related to Internet Expenses in eTRM. Can any one please specify them.IINM, it should be under AP/APPS schemas.
    SQL> select owner, object_name, object_type
    from dba_objects
    where object_name like 'OIE%';Thanks,
    Hussein

  • Inline View

    I am working in very important sector in Canada and using Oracle widely. There is a group of experienced managers and developer who discourage to use inline views. They have some reasons in addition to (may be misleading) information pass on by Oracle. According to them Inline views are �devils work�. It gives wrong results and poor in performance. They also refer an oracle bug, which I believe is a misleading info by Oracle (probably same guy).
    http://metalink.oracle.com/metalink/plsql/showdoc?db=Bug&id=1227266
    I have posted a question against that bug to Oracle (metalink.oracle.com) PL/SQL FORUM. I think Note:118978.1 is right and if we incorporate aliases we will never face problem. I have widely used inline views and never faced wrong results. In my opinion Inline views made life simple and easy. Its performance is excellent and save a lot of time rather to write multiple SQLs, which make the maintenance job difficult. Considering you an authority on Oracle. I want to seek expert opinion about Inline view. Please keep in mind that here we use lot of SQLs just to avoid inline views and some time convert some SQLs into real Views just to get rid of inline view. Your note could help me to convince my manager to allows us to use inline views.
    Regards,
    Amer

    I need comments from other experts using metlinks but some how not getting any response.Because it's pointless. If your managers and colleagues don't trust you why the heck should they listen to a bunch of nobodies like us> You've got Tom Kyte on your side, he's the Oracle VP of database technology, he's the biggest howitzer in the field. If they go up against him they're going to be flattened.
    Unfortunately there is no cure for human stupidity (I speak as a long term sufferer), and in my experience people with entrenched positions are rarely willing to admit that they were wrong. Particularly when any outsider can see that they are obviously wrong.
    As I see it, you have two choices:
    (1) Knuckle down, don't use inline views.
    (2) Be assertive, use inline views. When challenged demand that they both prove that your implementation is buggy and provide an adequate alternative (as performant, as easy to understand, more reliable).
    Be aware that if you take line (2) you must ensure your code is bulletproof: test it rigourously. By forcing them to look at the code, you can undermine their arguments with fact, an ounce of which is worth a ton of opinion.
    Cheers, APC

  • Oracle jdbc creating a table, sequence and trigger

    I'm trying to create a table with a sequence and with a trigger for that sequence. When I do this within Oracle Express edition I have the following SQL statements. Which DO run correctly inside Oracle Express using the same user I log in with JDBC.
    CREATE table "TEST" (
    "ID" NUMBER(10) NOT NULL,
    "NAME" VARCHAR2(20),
    constraint "TEST_PK" primary key ("ID")
    CREATE sequence "TEST_SEQ"
    CREATE trigger "BI_TEST"
    before insert on "TEST"
    for each row
    begin
    if :NEW."ID" is null then
    select "TEST_SEQ".nextval into :NEW."ID" from dual;
    end if;
    end;
    So now what I do is put each of these into a List of Strings and execute 1 by one like this:
    List<String> commands = new ArrayList<String>(4);
    commands.add("Create table ...");
    commands.add("Create sequence ...");
    commands.add("Create trigger...");
    st = con.createStatement();
    for (String command : commands) {
    st.execute(command);
    etc...
    But I get an error with the trigger statement. "Error with Oracle command: ORA-00942: table or view does not exist"
    It seems to me that Oracle has not yet seen the new table at this point. or maybe my user can create tables but not triggers? If that's the case why did it work in the express application itself?
    TIA

    SproketBoy wrote:
    But I get an error with the trigger statement. "Error with Oracle command: ORA-00942: table or view does not exist"Keep in mind: Oracle is not lying to you.
    >
    It seems to me that Oracle has not yet seen the new table at this point. or maybe my user can create tables but not triggers? If that's the case why did it work in the express application itself?No, DDL commands cause an explicit commit. As soon as you invoke them, the change is permanent. If it was a rights problem, you'd get a different ORA error stating that, it won't silently fail.
    Lets not assume it is anything difficult, perhaps there is simply a typo in a name somewhere?

  • Best practice for VPD and remote tables

    Not specifically an HTMLDB question, but here goes...
    HTMLDB 1.6 on 9.2.0.4 connecting over database link (fixed username/password) to 9.2.0.4
    I've currently "wrapped" access to the remote tables in views, i.e. view "T" in the HTMLDB parsing schema LOCAL_USER is defined as "SELECT * FROM T@remote"
    I'd like to put VPD controls on my backend tables, but I don't get how v('APP_USER') (or even APP_USER put into an application context) would be seen by the remote database.
    Should I just put VPD policies on LOCAL_USER's views and call it a day?
    Thanks for input!
    -John

    If you implemented the VPD in the remote database, what would your VPD be restricting? All queries would apply the policy based on the DB link fixed username resulting in all users of the HTML DB application having same policy restrictions.
    The policy in the remote database does not has access to the value of v('APP_USER'). That value is only available in the database that has HTML DB. You would have to write APIs in the remote database in PL/SQL functions/procedures to pass in the V('APP_USER') value to the remote database. This is doable, but cumbersome.
    If you want to have your policy modify your WHERE clause on the fly based on your HTML DB user account, then I would implement the VPD in the database which has your HTML DB repository. I am not sure which of the two scenarios below occur when doing a SELECT * FROM T.
    1.) The query goes across the database link, gets all the data out of table T in the remote database, passes back to the HTML DB database, and applies the policy WHERE clause modification in the HTML DB database.
    2.) The query applies the policy WHERE clause modification to the view, goes across the database link with the WHERE clause modified, and gets only the data allowed based on the policy from the remote database.
    You should test this out to find out for performance purposes what query is actually performed on the remote database.
    As always if anyone sees anything inaccurate in what I have written, please correct me.
    Mike

  • Table or view "DMSYS.MINING_DATA_BUILD_V  does not exist

    Hi all
    I am trying to run the ABNDemo.java. Before compiling the code I made the following changes. I am using Oracle 10g, 10.1.0.2.
    DB URL =”jdbc:oracle:thin:@localhost:1521:orcl”
    Username = “system”
    Password=”sdsfdvd”
    DATA_SCHEMA_NAME=”DMSYS”
    I compiled it successfully but when I am running it I am getting the following error.
    C:\oracle\product\10.1.0\db_1\dm\demo\sample\java>javac ABNDemo.java
    C:\oracle\product\10.1.0\db_1\dm\demo\sample\java>java ABNDemo
    oracle.dmt.odm.InvalidArgumentException: Table or view "DMSYS.MINING_DATA_BUILD_
    V" does not exist.
    at oracle.dmt.odm.data.LogicalDataSpecification.formLDSFrom2DDBTable(Log
    icalDataSpecification.java:466)
    at oracle.dmt.odm.data.LogicalDataSpecification.create(LogicalDataSpecif
    ication.java:647)
    at oracle.dmt.odm.settings.function.MiningFunctionSettings.prepareMFS(Mi
    ningFunctionSettings.java:2229)
    at oracle.dmt.odm.settings.function.ClassificationFunctionSettings.creat
    e(ClassificationFunctionSettings.java:460)
    at ABNDemo.buildModel(ABNDemo.java:93)
    at ABNDemo.main(ABNDemo.java:55)
    Thanx
    vijai

    'user schema' refers to a normal database user account, e.g. scott
    For more details as how to execute 10.1 Java demo programs, please check the README.txt file which is located at:
    $ORACLE_HOME/dm/demo/sample/java/README.txt
    Xiafang

  • Developing database views between Oracle and SQL Server tables

    I am on Oracle 10.2, my organization has many SQL Server databases as well and has now made
    SQL server as company standard so many new databases will be developed in SQL Server. It is of course
    not possible to convert all Oracle databases to SQL Server, so a mix environment will exist. Two questions:
    1.     Is it possible to develop database views in Oracle (10g in my case) which join Oracle tables with tables in SQL Server 2008? If yes, how. I have seen some heterogeneous connectivity setup to connect SQL Server to Oracle, but not sure whether it is possible to develop a database view across two databases.
    2.     I know it is not a SQL Server forum, but many DBA’s know both Oracle and SQL Server. Is it possible to develop views in SQL Server (SQL Server 2008 R2 in my case) which join Oracle 10g and SQL Server 2008 tables? I know in SQL Server, there is way to set up linked servers, but do not know whether it is possible to develop views.
    Thanks a lot for your insight.

    You can create views that join local Oracle tables and remote SQL Server tables. I'm pretty sure you can do the reverse as well but I haven't personally done it.
    However, I would be very concerned about the performance you'd get if you created that sort of view. You'd very frequently end up in a situation where Oracle has to pull all the data in the remote table across the database link in order to apply predicates and join the data locally. That could be disastrous from a performance standpoint.
    Justin

  • Problem encountered when join two remote tables in a materialized view

    I'm using oracle 9.2.0.6
    1> I have two tables:
    CREATE TABLE TEST
    A VARCHAR2(100 BYTE),
    C DATE
    CREATE TABLE TEST1
    A VARCHAR2(100 BYTE),
    B TIMESTAMP
    2>. I defined a prebuild table:
    CREATE TABLE MV_TEST1
    ID1 ROWID,
    A VARCHAR2(100 BYTE),
    ID2 ROWID,
    B TIMESTAMP(6),
    C DATE
    3> I created mview logs:
    CREATE MATERIALIZED VIEW LOG ON PSI_TEST.TEST
    WITH ROWID
    INCLUDING NEW VALUES;
    CREATE MATERIALIZED VIEW LOG ON PSI_TEST.TEST1
    WITH ROWID
    INCLUDING NEW VALUES;
    4> when I create mview:
    CREATE MATERIALIZED VIEW PSI_TEST.MV_TEST1
    ON PREBUILT TABLE WITH REDUCED PRECISION
    REFRESH FAST ON DEMAND
    WITH PRIMARY KEY
    AS
    select
    test.rowid id1,
    test.a,
    test1.rowid id2,
    test1.b,
    cast(null as date) c
    from test , test1
    where test.a = test1.a(+);
    It is created successfully.
    5> problem:
    when I use remote tables to do the same thing, say test and test1 are in another instance and are connected by a dbLink, I couldn't create the mview successfully:
    CREATE MATERIALIZED VIEW PSI_TEST.MV_TEST1
    ON PREBUILT TABLE WITH REDUCED PRECISION
    REFRESH FAST ON DEMAND
    WITH PRIMARY KEY
    AS
    select
    a.rowid id1,
    a.a,
    b.rowid id2,
    b.b,
    cast(null as date) c
    from test@dbl a, test1@dbl b
    where a.a = b.a(+);
    when run above statement, I got:
    ORA-12015: cannot create a fast refresh materialized view from a complex query
    Any ideas? Or joining two table through a dblink for a mview is not allowed at all?
    Thanks in advance.

    No one has a clue?
    Message was edited by:
    lzhwxy

  • ORA-01092: ORACLE instance terminated. Disconnection forced ORA-00942: table or view does not exist on 12C RAC

    Hi Geeks,
    I have encountered an issue while starting up my database on 12c RAC.
    Till mount it goes fine but when i attempt to open it throws me an error.
    Total System Global Area 1.5400E+10 bytes
    Fixed Size                  4737560 bytes
    Variable Size            2952791528 bytes
    Database Buffers         1.2415E+10 bytes
    Redo Buffers               26857472 bytes
    Database mounted.
    SQL> alter database open;
    alter database open
    ERROR at line 1:
    ORA-01092: ORACLE instance terminated. Disconnection forced
    ORA-00942: table or view does not exist
    Process ID: 11338068
    Session ID: 1429 Serial number: 3
    Here is the trace file output...
    ORACLE_HOME = /oracle_home/app/orahome
    System name:    AIX
    Node name:      INS1
    Release:        1
    Version:        7
    Machine:        00C8CCA74C00
    Instance name: INST1
    Redo thread mounted by this instance: 1
    Oracle process number: 7
    Unix process pid: 20381876, image: oracle@ins1 (TNS V1-V3)
    *** 2014-11-27 22:49:20.892
    *** SESSION ID:(197.5) 2014-11-27 22:49:20.892
    *** CLIENT ID:() 2014-11-27 22:49:20.892
    *** SERVICE NAME:() 2014-11-27 22:49:20.892
    *** MODULE NAME:(sqlplus@ins1 (TNS V1-V3)) 2014-11-27 22:49:20.892
    *** ACTION NAME:() 2014-11-27 22:49:20.892
    2014-11-27 22:49:20.889716 : Start recovery for domain=0, valid=0, flags=0x4
    *** 2014-11-27 22:49:24.580
    Successfully allocated 32 recovery slaves
    Using 3 overflow buffers per recovery slave
    *** 2014-11-27 22:49:24.740
    Thread 1 checkpoint: logseq 15, block 2, scn 3510749
      cache-low rba: logseq 15, block 3
        on-disk rba: logseq 15, block 72, scn 3510824
      start recovery at logseq 15, block 3, scn 0
    *** 2014-11-27 22:49:24.981
    Started resilvering redo thread 1 seq 15 blocks 72-73
    *** 2014-11-27 22:49:24.994
    Completed resilvering redo thread 1 seq 15
    *** 2014-11-27 22:49:24.994
    Started writing zeroblks thread 1 seq 15 blocks 74-81
    *** 2014-11-27 22:49:24.994
    Completed writing zeroblks thread 1 seq 15
    ==== Redo read statistics for thread 1 ====
    Total physical reads (from disk and memory): 4096Kb
    -- Redo read_disk statistics --
    Read rate (ASYNC): 35Kb in 0.25s => 0.14 Mb/sec
    Longest record: 0Kb, moves: 0/104 (0%)
    Longest LWN: 2Kb, moves: 0/33 (0%), moved: 0Mb
    Last redo scn: 0x0000.0035922b (3510827)
    ----- Recovery Hash Table Statistics ---------
    Hash table buckets = 262144
    Longest hash chain = 1
    Average hash chain = 25/25 = 1.0
    Max compares per lookup = 1
    Avg compares per lookup = 151/176 = 0.9
    *** 2014-11-27 22:49:25.007
    KCRA: start recovery claims for 25 data blocks
    *** 2014-11-27 22:49:25.039
    KCRA: blocks processed = 25/25, claimed = 25, eliminated = 0
    *** 2014-11-27 22:49:25.054
    Recovery of Online Redo Log: Thread 1 Group 6 Seq 15 Reading mem 0
    *** 2014-11-27 22:49:25.060
    Completed redo application of 0.02MB
    *** 2014-11-27 22:49:25.235
    Completed recovery checkpoint
    ----- Recovery Hash Table Statistics ---------
    Hash table buckets = 262144
    Longest hash chain = 1
    Average hash chain = 25/25 = 1.0
    Max compares per lookup = 1
    Avg compares per lookup = 176/176 = 1.0
    Recovery sets nab of thread 1 seq 15 to 74 with 8 zeroblks
    *** 2014-11-27 22:49:26.000
    2014-11-27 22:49:26.000433 : Validate domain 0
    2014-11-27 22:49:26.001348 : Validated domain 0, flags = 0x0
    *** 2014-11-27 22:49:28.315
    Count of ofsmtab$: 0 entries
    *** 2014-11-27 22:49:28.732
    ORA-00942: table or view does not exist
    ORA-00942: table or view does not exist
    *** 2014-11-27 22:49:28.738
    USER (ospid: 20381876): terminating the instance due to error 942

    In my case the issue has fixed by executing the following..
    grant SELECT on SYS.USER$ to XDB;
    grant SELECT on SYS.USER$ to CTXSYS;
    grant SELECT on SYS.USER$ to DVSYS;
    grant SELECT on SYS.USER$ to LBACSYS;
    grant SELECT on SYS.USER$ to APEX_040200;
    grant SELECT on SYS.USER$ to DV_SECANALYST; 
    Refer the above screen shot...

  • Instead-of Trigger of View on a Remote Table Fails!!!

    Hi all,
    I'm trying to create an INSTEAD OF (UPDATE or INSERT) trigger on a view V1 in DATABASE DB1 (Linux 7.3 or 7.2, ORACLE 9.2.0.1.0 - Production).The view V1 is created on a remote table through a DBLINK.But I always get such error when I update the view V1 using statements such as "update v1 set oid=oid+1000" :
    ORA-03113 end-of-file on communication channel
    But I can execute those statements successfully in Oracle of version 9.0.1.0.0 .
    What I want to say is that if some special configs is needed to support instead-of trigger of a view on a remote table ?

    Hi all,
    I'm trying to create an INSTEAD OF (UPDATE or INSERT) trigger on a view V1 in DATABASE DB1 (Linux 7.3 or 7.2, ORACLE 9.2.0.1.0 - Production).The view V1 is created on a remote table through a DBLINK.But I always get such error when I update the view V1 using statements such as "update v1 set oid=oid+1000" :
    ORA-03113 end-of-file on communication channel
    But I can execute those statements successfully in Oracle of version 9.0.1.0.0 .
    What I want to say is that if some special configs is needed to support instead-of trigger of a view on a remote table ?

  • SSMA for Oracle 6.0 Cannot connect to Oracle DB reporting "table or view does not exist"

    SSMA For Oracle v6.0.0
    MS SQL Server Enterprise 64bits v11.0.3000.0
    Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
    Symptom:
    when connecting Oracle, it reports error "Common Requirement: User does not have required permissions". Then it reports error: "Error occurred while collecting data."
    The following is log:
    [Generic: Mandatory] [1500/1] [2015-03-03 04:19:29]: SQL Server Migration Assistant for Oracle v6.0.0
    [Generic: Mandatory] [1500/1] [2015-03-03 04:19:29]: Starting assembly: SSMAforOracle, Version=6.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35
    Created: 7/22/2014 4:42:22 PM
    Last Modified: 7/22/2014 4:42:22 PM
    OS Version: Microsoft Windows NT 6.1.7601 Service Pack 1
    OS architecture: x64
    Processor architecture: AMD64
    Current culture: en-US
    UI culture: en-US
    [Collector: Mandatory] [1500/4] [2015-03-03 04:20:04]: Oracle connection provider: OracleClient.
    [Collector: Mandatory] [1500/4] [2015-03-03 04:20:04]: Oracle connection mode: Standard.
    [Collector: Mandatory] [1500/4] [2015-03-03 04:20:06]: Oracle server version: '11.2.0.3.0'.
    [Gui: Error] [1500/4] [2015-03-03 04:20:12]: LowLevelAdapter.ReadSource : Read Source error: Microsoft.SSMA.Framework.Generic.Collectors.CollectorException: Error occurred while collecting data. ---> System.Data.OracleClient.OracleException: ORA-00942: table
    or view does not exist
       at System.Data.OracleClient.OracleConnection.CheckError(OciErrorHandle errorHandle, Int32 rc)
       at System.Data.OracleClient.OracleCommand.Execute(OciStatementHandle statementHandle, CommandBehavior behavior, Boolean needRowid, OciRowidDescriptor& rowidDescriptor, ArrayList& resultParameterOrdinals)
       at System.Data.OracleClient.OracleCommand.ExecuteScalarInternal(Boolean needCLStype, Boolean needRowid, OciRowidDescriptor& rowidDescriptor)
       at System.Data.OracleClient.OracleCommand.ExecuteScalar()
       at Microsoft.SSMA.Framework.Generic.DbUtilities.SsmaDbCommand.ExecuteScalar()
       at Microsoft.SSMA.Framework.Oracle.Collector.OracleObjectCollector.ExecuteScalarToInt(IDbConnection connection, String text)
       at Microsoft.SSMA.Framework.Oracle.Collector.OracleObjectCollector.GetCountForExcludedSchemas(IDbConnection connection, IEnumerable`1 excludedSchemas, Int64 version)
       at Microsoft.SSMA.Framework.Oracle.Collector.OracleObjectCollector.CountObjects(IDbConnection connection, Int64 serverVersion, OracleCollectionFilter filter, Set`1 excludedSchemas)
       at Microsoft.SSMA.Framework.Oracle.Collector.OracleObjectCollector.CollectDataIntoMetabase(XMetabase xMetabase, IDbConnection connection, Int64 serverVersion, OracleCollectionFilter filter, IUIProgressBarProvider progressBarProvider, IUIStopOperationProvider
    stopOperationProvider, ICollectionContext context)
       at Microsoft.SSMA.Framework.Oracle.Collector.OracleObjectCollector.CreateMetabaseAndCollectData(IDbConnection connection, String xmlConnectionParameters, XNode xFilter, IUIProgressBarProvider progressBarProvider, IUIStopOperationProvider stopOperationProvider,
    ICollectionContext context)
       --- End of inner exception stack trace ---
       at Microsoft.SSMA.Framework.Generic.Workspaces.Default.MetabaseWorkspaceItem.Connect(String connectionParameters, SecureString password)
       at Microsoft.SSMA.GUI.Product.OracleToMsSql.LowLevel.AppConnectToSourceOracle.ConnectToSourceStart(Object guiContext)
    [Gui: Error] [1500/4] [2015-03-03 04:20:12]: Exception: Error occurred while collecting data.
     site: Void Connect(System.String, System.Security.SecureString)
     source: Microsoft.SSMA.Framework.Generic.SSMAEnvironment
       at Microsoft.SSMA.Framework.Generic.Workspaces.Default.MetabaseWorkspaceItem.Connect(String connectionParameters, SecureString password)
       at Microsoft.SSMA.GUI.Product.OracleToMsSql.LowLevel.AppConnectToSourceOracle.ConnectToSourceStart(Object guiContext)
    [Gui: Error] [1500/4] [2015-03-03 04:20:12]: Inner Exception #1: ORA-00942: table or view does not exist
     site: Void CheckError(System.Data.OracleClient.OciErrorHandle, Int32)
     source: System.Data.OracleClient
     error code: -2146232008
       at System.Data.OracleClient.OracleConnection.CheckError(OciErrorHandle errorHandle, Int32 rc)
       at System.Data.OracleClient.OracleCommand.Execute(OciStatementHandle statementHandle, CommandBehavior behavior, Boolean needRowid, OciRowidDescriptor& rowidDescriptor, ArrayList& resultParameterOrdinals)
       at System.Data.OracleClient.OracleCommand.ExecuteScalarInternal(Boolean needCLStype, Boolean needRowid, OciRowidDescriptor& rowidDescriptor)
       at System.Data.OracleClient.OracleCommand.ExecuteScalar()
       at Microsoft.SSMA.Framework.Generic.DbUtilities.SsmaDbCommand.ExecuteScalar()
       at Microsoft.SSMA.Framework.Oracle.Collector.OracleObjectCollector.ExecuteScalarToInt(IDbConnection connection, String text)
       at Microsoft.SSMA.Framework.Oracle.Collector.OracleObjectCollector.GetCountForExcludedSchemas(IDbConnection connection, IEnumerable`1 excludedSchemas, Int64 version)
       at Microsoft.SSMA.Framework.Oracle.Collector.OracleObjectCollector.CountObjects(IDbConnection connection, Int64 serverVersion, OracleCollectionFilter filter, Set`1 excludedSchemas)
       at Microsoft.SSMA.Framework.Oracle.Collector.OracleObjectCollector.CollectDataIntoMetabase(XMetabase xMetabase, IDbConnection connection, Int64 serverVersion, OracleCollectionFilter filter, IUIProgressBarProvider progressBarProvider, IUIStopOperationProvider
    stopOperationProvider, ICollectionContext context)
       at Microsoft.SSMA.Framework.Oracle.Collector.OracleObjectCollector.CreateMetabaseAndCollectData(IDbConnection connection, String xmlConnectionParameters, XNode xFilter, IUIProgressBarProvider progressBarProvider, IUIStopOperationProvider stopOperationProvider,
    ICollectionContext context)

    Hi Airings,
    'ORA-00942: table or view does not exist'
    According to the error message, it seems that the migrating table or view does not exist in the database, or SSMA does not have access to it. To troubleshoot the issue, please check the following things.
     1. Verify that if the spelling of the table or view name is correct.
     2. If the table or view exists but is in a different schema from the current schema where the SQL is executing (in other word, the table doesn’t own by you, but owned by other user), the ORA-00942 error will return too. Resolve this by
    explicitly reference the table or view by specifying the schema name (schema_name.table_name).
    3. SSMA queries some additional catalog tables that you may not have permission to, please make sure that you grant the account permission to
     read sys.mlog$. For more details, please review this similar thread:
    Bug in SSMA For Oracle 6.0 for non-dba Oracle user.
    Reference:
    ORA-00942 Table or View Does Not Exist Oracle Error
    Thanks,
    Lydia Zhang
    Lydia Zhang
    TechNet Community Support

  • [SQL] inline view and order by on oracle 8.0.5

    Hi everyone.
    I am trying to sort data inside "inline view"
    on "Oracle8 Release 8.0.5.0.0 - Production".
    However, it did not work. Is this an oracle-bug?
    I got the oracle error , "ORA-00907".
    The sql script is like this:
    select ..............
    from (select ..... from .. where .... order by ...)
    where rownum <11
    However, the "exactly" same sql has no problem
    on "Oracle8i Enterprise Edition Release 8.1.7.0.0".
    Every response will be greatly appreciated.
    Thanks in advance.
    Ho.

    Order by cannot be used in a subquery while for inline view it is supported but in Oracle8i, release 8.1 and up
    Khurram

  • Fine tuning oracle inline view

    Hi All,
    i have a sql query (inline view) which is taking very long time (16 mins Approx) in our environment (Oracle 8.1.7 on Sun).
    Can anyone have any idea to either fine tune the query OR convert it into PL/SQL.
    Query:
    SELECT DISTINCT ML.MFG_LEVEL,          
    SUBSTR(ML.PROCESS_DESC,
    INSTR(ML.PROCESS_DESC, '_', 1, 2) + 1) AS FACILITY,
    SUBSTR(ML.PROCESS_DESC, 1, INSTR(ML.PROCESS_DESC, '_') - 1) AS PACKAGE_NAME,
    SUBSTR(ML.PROCESS_DESC,
    INSTR(ML.PROCESS_DESC, '_') + 1,
    INSTR(ML.PROCESS_DESC, '_', 1, 2) -
    INSTR(ML.PROCESS_DESC, '_') - 1) AS BASIC_TYPE,
    BT.BATCH_TIME_MEAN / BS.BATCH_SIZE AS RUNTIME_BASE,
    ML.TASK_DESC,
    ML.RESOURCE_DESC AS RESOURCE_NAME,
    ML.PROCESS_DESC
    FROM (SELECT DISTINCT RP.VALUE AS MFG_LEVEL,
    TM.TASK_DESC,
    RM.RESOURCE_DESC,
    PC.PROCESS_DESC
    FROM DWH_MCD.TASK_MASTER TM,
    DWH_MCD.TASK_PARAMETER_MASTER TP,
    DWH_MCD.RESOURCE_MASTER RM,
    DWH_MCD.PROCESS_PLAN PP,
    DWH_MCD.PROCESS PC,
    DWH_MCD.RESOURCE_PARAMETER RP,
    DWH_MCD.PARAMETER_TYPE PT
    WHERE PC.PROCESS_ID = PP.PROCESS_ID AND PP.TASK_ID = TM.TASK_ID AND
    TM.TASK_ID = TP.TASK_ID AND TP.RESOURCE_ID = RM.RESOURCE_ID AND
    RP.RESOURCE_ID = RM.RESOURCE_ID AND
    PT.PARAMETER_TYPE_ID = RP.PARAMETER_TYPE_ID AND
    PT.PARAMETER_TYPE_ID = 220037 -- AREA i.e MFG_LEVEL
    AND(TM.TASK_DESC NOT LIKE '%SUBCON%' OR
    PC.PROCESS_DESC NOT LIKE '%VF%')) ML,
    (SELECT DISTINCT TP.VALUE AS BATCH_TIME_MEAN,
    TM.TASK_DESC,
    RM.RESOURCE_DESC,
    PC.PROCESS_DESC
    FROM DWH_MCD.TASK_MASTER TM,
    DWH_MCD.TASK_PARAMETER_MASTER TP,
    DWH_MCD.RESOURCE_MASTER RM,
    DWH_MCD.PROCESS_PLAN PP,
    DWH_MCD.PROCESS PC,
    DWH_MCD.RESOURCE_PARAMETER RP,
    DWH_MCD.PARAMETER_TYPE PT
    WHERE PC.PROCESS_ID = PP.PROCESS_ID AND PP.TASK_ID = TM.TASK_ID AND
    TM.TASK_ID = TP.TASK_ID AND TP.RESOURCE_ID = RM.RESOURCE_ID AND
    RP.RESOURCE_ID = RM.RESOURCE_ID AND
    PT.PARAMETER_TYPE_ID = TP.PARAMETER_TYPE_ID AND
    PT.PARAMETER_TYPE_ID = 220030 -- BATCH TIME MEAN
    AND(TM.TASK_DESC NOT LIKE '%SUBCON%' OR
    PC.PROCESS_DESC NOT LIKE '%VF%')) BT,
    (SELECT DISTINCT TP.VALUE AS BATCH_SIZE,
    TM.TASK_DESC,
    RM.RESOURCE_DESC,
    PC.PROCESS_DESC
    FROM DWH_MCD.TASK_MASTER TM,
    DWH_MCD.TASK_PARAMETER_MASTER TP,
    DWH_MCD.RESOURCE_MASTER RM,
    DWH_MCD.PROCESS_PLAN PP,
    DWH_MCD.PROCESS PC,
    DWH_MCD.RESOURCE_PARAMETER RP,
    DWH_MCD.PARAMETER_TYPE PT
    WHERE PC.PROCESS_ID = PP.PROCESS_ID AND PP.TASK_ID = TM.TASK_ID AND
    TM.TASK_ID = TP.TASK_ID AND TP.RESOURCE_ID = RM.RESOURCE_ID AND
    RP.RESOURCE_ID = RM.RESOURCE_ID AND
    PT.PARAMETER_TYPE_ID = TP.PARAMETER_TYPE_ID AND
    PT.PARAMETER_TYPE_ID = 220008 -- BATCH SIZE
    AND(TM.TASK_DESC NOT LIKE '%SUBCON%' OR
    PC.PROCESS_DESC NOT LIKE '%VF%')) BS
    WHERE ML.TASK_DESC = BT.TASK_DESC AND ML.RESOURCE_DESC = BT.RESOURCE_DESC AND
    ML.PROCESS_DESC = BT.PROCESS_DESC AND ML.TASK_DESC = BS.TASK_DESC AND
    ML.RESOURCE_DESC = BS.RESOURCE_DESC AND
    ML.PROCESS_DESC = BS.PROCESS_DESC;
    Please feel free to ask me for more information if needed.
    Thank You.
    Best Regards,
    Jawahar.

    Jawahar,
    Before you run this sql statement analyse those tables which you use in that query using dbms_utility.analyse_schema() then create one Mview for that query. Before you do all this use "Explain Plan for" this query and observe the statistics. See you need to create a table for Explain Plan. You can find that script in ORACLE_HOME/rdbms/admin/utlxplan.sql
    Kamalesh JK
    jkkstar inc

  • Where do i see all the default tables and views in oracle 10g

    hi,
    I have installed oracle 10g in the linux os.
    I just wanna see the list of deffault tables and views created by oracle.
    can anyoone hlep me on this
    thanx in advance....

    Check DBA_OBJECTS for all seeded objects in an Oracle database. For tables, check DBA_TABLES. For views, check DBA_VIEWS. All of this is documented in the fine documentation - take some time out to read thru it.
    http://docs.oracle.com/cd/E11882_01/server.112/e25513/statviews_4156.htm#REFRN23146
    http://docs.oracle.com/cd/E11882_01/server.112/e25513/statviews_5056.htm#sthref2482
    http://docs.oracle.com/cd/E11882_01/server.112/e25513/statviews_5085.htm#sthref2521
    HTH
    Srini

Maybe you are looking for

  • HP LaserJet 1536dnf MFP _ Password

    Hi, I have a HP LaserJet 1536dnf MFP and I need to connect it to my home wireless network, but it is asking for a password that I can't remember that I have created. Could you please help me to reset the printer?  Thanks.

  • Bridge

    I'm using Adobe CC for a while now, with everything working properly. However, since a few weeks i cannot startup Adobe Bridge anymore. I get the following message. I already reinstalled it, but it doesn't change anything. Can anyone help me? Process

  • Read a XML node value/attribute value from a CLOB

    Hello, I can write SQL/ - PL/SQL "straightforward" but now I have a problem what is to big for me.  I hop that someone can help. We create by code a xml structure and write these into the oracle database CLOB field. I'm sorry to say that a xml text s

  • The comp doesn't recgonize the ipod.

    Hey. My friend gave me his Ipod because it hasn't been working. the ipod is one of the first models, it ISNT colorful , and it has this click wheel and the buttons on it. okay, when i turn on the ipod it shows this: www.apple.com/support/ipod it show

  • How do I get photos from aperture to iPhone?

    so far, photostream seems to be working fine as far as moving pics from my iPhone to Aperture 3/iPhoto. After the IOS5 update, I realized I have none of the pictures on my phone I originally had. Is there a new process to get pictures from Aperture /