Oracle 8i and DB2 Connectivity

Hi,
I dont know whether this is right forum to post this query.
I want to connect to DB2 from Oracle 8i. I have read some documentation about Oracle gateways but it is not clear of how exactly we can connect to DB2.
If any one has done this before please let me know th detail steps of how we can connect to DB2.

You can use oracle product Interconnect. If you search on interconnect you will get your answer.

Similar Messages

  • OWB and DB2 connection

    I have connected Oracle 9i and DB2 v7 and query DB2 in SQL Plus is fine. However, it doesn't for the connection between OWB and DB2.
    Anyone can help?
    Thanks!

    Try the following and use the database link as the source.
    1. Copy inithsodbc.ora to initQA_DB2.ora in $ORACLE_HOME\hs\admin
    HS_FDS_CONNECT_INFO=DNS_NAME_OF_YOUR_CONNECTION
    HS_FDS_TRACE_LEVEL=0
    2. Add the following lines to listener.ora in Oracle server ($ORACLE_HOME\NETWORK\ADMIN)
    (SID_DESC =
    (SID_NAME = QA_DB2)
    (ORACLE_HOME = $ORACLE_HOME)
    (PROGRAM = hsodbc)
    3. Add the following lines to tnsnames.ora in Oracle server ($ORACLE_HOME\NETWORK\ADMIN)
    DB= (DESCRIPTION=
    (ADDRESS=(PROTOCOL=tcp)
    (HOST=localhost)
    (PORT=1521)
    (CONNECT_DATA = (SERVICE_NAME=QA_DB2)
    (HS = OK)
    4. Execute CATalog script for Heterogeneous Services in Oracle server ($ORACLE_HOME\RDBMS\ADMIN\caths.sql)
    5. Create database link
    drop public DATABASE LINK dwh_qa_db2;
    CREATE public DATABASE LINK dwh_qa_db2 CONNECT TO "carlosmo" IDENTIFIED BY "E1Qual" USING 'DB2';
    6. Test the connection
    SELECT *
    FROM SomeTable@dwh_qa_db2

  • Developer 6i and DB2 connectivity.

    I am using Oracle8i with Developer 6i.
    I need to connect to DB2/400 (running under OS/400) from Forms Developer 6i
    i have IBM AS400 Client Access (version : 3, release : 2,
    modification level : 0 ) installed on this machine, which
    is working allright, i have checked it by using datatransfer from
    AS/400.
    the username on DB2 is ORACLE (password is same as username).
    i have created ODBC system data source (named SYSDB2) for OCA connection
    while i connect from sqlplus, it connects with some error messages as
    shown below, however it works allright for querying.
    SQL> CONN ORACLE/ORACLE@ODBC:SYSDB2 ;
    ORA-00022: invalid session id; access denied
    ORA-00022: invalid session id; access denied
    ORA-00022: invalid session id; access denied
    Error accessing PRODUCT_USER_PROFILE
    Warning: Product user profile information not loaded!
    You may need to run PUPBLD.SQL as SYSTEM
    Server not available or version too low for this feature
    ORA-00022: invalid session id; access denied
    Connected.
    SQL>
    i have run PUPBLD.SQL but had no affect on these messages .
    When i try to create data dictionary views for DB2 from this connection
    by running script (Db4dmbld.sql) it does not create data dictionary.
    its fine till this happens, the real problem is that i am
    unable to connect to db2 by using odbc datasource from forms6i.
    when i try to connect it shows some special characters in a
    message box which can't provide any information.
    please let me know if there is any fix to this problem.
    regards,
    aamir.

    Hi,
    the site where you can find it is http://technet.oracle.com/doc/gateways.htm
    The gateway has no database functions. The gateway provides an interface by which the Oracle server can direct SQL operations to a DB2 database.
    Using a database link, the gateway is identified to the Oracle server. The database link is the same construct used to identify other Oracle server databases.
    Tables on the DB2 server are referenced in SQL as:
    table_name@dblink_name
    or
    owner.table_name@dblink_name
    If you create synonyms or views in the Oracle server database, you can refer to tables on the DB2 server using simple names as though the table is local to the Oracle server.
    When the Oracle server encounters a reference to a table on the DB2 server, the applicable portion of the SQL statement is sent to the gateway for processing. Any host variables associated with the SQL statement are bound to the gateway and, therefore, to the DB2 server.
    The gateway is responsible for sending these SQL statements to the DB2 server for execution and for fielding and returning responses. The responses are data or messages. Any conversions between Oracle datatypes and DB2 datatypes are performed by the gateway. The Oracle server and the application read and process only Oracle datatypes.
    --Samson
    <BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>Originally posted by Aamir Muhammad ([email protected]):
    Thanks Samson for you only reply on the
    topic, would you kindly tell me where can i find Oracle's Transaction Gateway for AS/400?
    Inspite all appreciation that i feel for you, What i think is that Gateways are used to establish connections between two databases not between a tool and a database like forms and AS400.<HR></BLOCKQUOTE>
    null

  • Oracle 10g and internet connection

    I recently installed a program which uses and installed the Oracle 10g database, but cannot run the database while I have an internet connection. If I disable my internet, I can run Oracle and my program. If I am connected to the internet and run the program it pops up this box:
    DATABASE LOGIN FAILED
    +... due to Oracle condition:+
    ORA-12541: TNS:no listener
    OK
    When I click Ok, it pops up a new box with 2 tabs: one asking for me to:
    Choose a (named database)
    This installation stores data in a named Oracle database.
    Since you may have several such databases, please select the name of
    your desired database from the list below.
    Note: If you are connecting to a local, single-user database, it may not have
    a name, or its name may not work.  In that case, you would need to choose
    the entry "<<always use default>>".
    There is a drop down box with 3 choices for the Database to use for this installation: XE, ORACLR_CONNECTION_DATA, and <<always use default>>
    The other tab is:
    Describe Privileged Account
    For maintenance purposes, this system also needs the name and password of
    a privileged Oracle user account.  It uses this privileged account
    only as needed, for various setup and maintenance tasks, such as
    o     creating the application's user account,
    o     providing it with storage space,
    o     providing backup/restore services,
    o     applying software updates.
    Please enter the privileged account's name and password below.
    If you do not know the account's name and password, please contact your
    Oracle database administrator (DBA).
    And it is asking for a user name and password. The Oracle help said that info should have been displayed somewhere during the Oracle installation process, but being as though I installed another program that did the Oracle, I don't think I ever saw it.
    I think it may matter:
    XP Pro SP 3
    2.4 GHz processor
    3 GB RAM
    To summarize; is there a way to run the Oracle database and my internet connection?
    Finally, I apologize for likely not providing all you would need to answer my question, I will provide anything else I can if it will help.
    Thanks
    gj

    Hi, thanks for the quick response.
    I went through the steps in the loopback adapter installation link you provided and have added a loopback adapter. When I do the ipconfig/all I get the following for the loopback adapter:
    Ethernet adapter Local Area Connection 4:
    Connection-specific DNS Suffix.....:
    Description...............................: Microsoft Loopback Adapter
    Dhcp Enabled...........................: No
    IP Address...............................: 192.168.25.129
    Subnet Mask............................: 255.255.255.0
    Default Gateway.......................:
    So it appears that is good to go. The issue still persists. Below is system information and Oracle information.
    System:
    Microsoft XP
    Professional
    Version 2002
    Service Pack 3
    Registered to:
    Me
    My company
    serial #
    Computer:
    Intel(R) Core (TM) i5 CPU
    M 520 @ 2.40 GHz
    2.39 GHz, 2.92 GB of RAM
    Physical Address Extension
    And Oracle is:
    Oracle Database 10g Release 2 (10.2.0.1) Express Edition for Microsoft Windows

  • DreamWeaver CS5, PHP and DB2 Connections

    Hi,
    I have been playing around with a XAMPP server, a mySQL database and DW CS5. This all works great and DW is a great assistant compiling the necessary PHP code so I dont have to worry about all that.
    I do have a number of DB2 database I would like to attach to and there is nothing untuitive in DW allowing me to connect to DB2 databases. Has anyone seen any useful examples here
    All my Apache and DB2 server are running on Linux hence Windows samples will not be that useful to me.
    ThnX in advance for any hints.
    - Bjoern

    Hi,
    I have been playing around with a XAMPP server, a mySQL database and DW CS5. This all works great and DW is a great assistant compiling the necessary PHP code so I dont have to worry about all that.
    I do have a number of DB2 database I would like to attach to and there is nothing untuitive in DW allowing me to connect to DB2 databases. Has anyone seen any useful examples here
    All my Apache and DB2 server are running on Linux hence Windows samples will not be that useful to me.
    ThnX in advance for any hints.
    - Bjoern

  • Oracle Warehouse Builder DB2 connectivity

    hi.
    is any one has the experience to use the OWB3i to connect to the DB2.
    please tell me the way to do it.
    thank you
    cindy

    Hi,
    The gateway that Oracle provides for this purpose is Pure
    Integrate.In pure integrate define a project(as we do in
    warehouse builder).Then configure your ODBC source(it supports
    SQl server, MS Access and variuos other Databases).Once defined
    and configured take export of the project and import in
    warehouse builder.
    In OWB then You can keep on adding various modules and other
    object in the imported Projects.The imported project will have
    source module as configured in Pure integrate.With this you
    don't need to export SQl server objects as flat files.

  • JSP and DB2 Connection

    I tried to use this class in my jsp page to connect to the DB2 database, However, no data from the DB appears on the page and i get no errors whatsoever. Can anyone be kind enough to take a look? Thanks
    package WH;
    import java.sql.*;
    import java.sql.Statement;
    public class DbConnect1 {
    private String dbUser = "XXX";
    private String dbPasswd = "XXX";
    private String dbDriver = "COM.ibm.db2.jdbc.app.DB2Driver";
    private String dbURL = "jdbc:db2:http://xx.xx.xxx.xx:8080/invsys";
    private Connection dbCon;
    public DbConnect1(){}
    public boolean connect() throws ClassNotFoundException,SQLException{
    try
    Class.forName(dbDriver);
    System.out.println("Loaded the instantDB JDBC driver.");
    dbCon = DriverManager.getConnection(dbURL, dbUser, dbPasswd);
    System.out.println("Created and connected to database TimingTest");
    return true;
    catch (Throwable e)
    e.printStackTrace();
    System.out.println("FAIL LAHHHHHHHHHHHH");
    return false;
    public void close() throws SQLException{
    dbCon.close();
    //accepts the SQL query in the form of a string from the JSP file in which this bean is implemented
    public ResultSet execSQL(String sql) throws SQLException{
    System.out.println("haha");
    //initiates the connection with the dbCon connection object
    Statement s = dbCon.createStatement();
    ResultSet r = s.executeQuery(sql);
    return (r == null) ? null : r;
    public int updateSQL(String sql) throws SQLException{
    Statement s = dbCon.createStatement();
    int r = s.executeUpdate(sql);
    return (r == 0) ? 0 : r;

    Here is a copy of my JSP file.
    <%@ page language='java' %>
    <%@ page import="java.sql.*" %>
    <jsp:useBean id="DbConnectBean1" scope="page" class="WH.DbConnect1" />
    <%
         //Get status
         /*String message;
         String status = request.getParameter("status").trim();
         if (status == "duplicateEmail")
         message="Please try again. An account with the same emaill address has already been created.";
         else if (status == "deleteOk")
         message="Delete successful.";
         else
              message="";*/
    //Get Contacts
         String name;
         String email;
         String extNo;
         String phoneNo;
         String remarks;
         String SQLstmt;
         SQLstmt = "Select * from CONTACT";
    if (DbConnectBean1.connect()==true){
    %>
    <html>
    <head>
    <title>Display Contacts</title>
    <script src="validation.js" language="Javascript"></script>
    <script Language="JavaScript">
    //Perform Validation
    /* function checkForm() {
    var alertString=checkChkBox(theForm.chkItem.value);
         formSubmit(alertString);
    </script>
    </head>
    <body bgcolor="#ffffff">
    <form action="USRDelContact.jsp" name="theForm" onsubmit="return checkForm();">
    </form>
    <table>
    <tr>
    <td><input type="chkAll" id="chkAll"onclick="checkAll(document.theForm.chkItem)"/></td>
    <td>Name</td>
    <td>Extension No.</td>
    <td>Mobile Phone No.</td>
    <td>Email Address</td>
    <td>Remarks</td>
    <td> </td>
    </tr>
    <%
         ResultSet r = DbConnectBean1.execSQL(SQLstmt);
         while (r.next()){
    %>
    <tr>
    <td><input type="checkbox" name="chkItem" id="chkItem" value="<%= r.getString("Email")%>"/></td>
    <td><%= r.getString("Emp_Name")%></td>
    <td><%= r.getString("Ext_No")%></td>
    <td><%= r.getString("Cellphone")%></td>
    <td><a href="mailto:<%= r.getString(Email")%">"><%= r.getString("Email")%></a></td>
    <td><%= r.getString("Remarks")%></td>
    <td><a href="USREditContact.jsp?email=<%= r.getString("Email")%>">Edit</a></td>
    </tr>
    <%
    if (r.next()==false)
    %>
    <tr>
    <td colspan="7">There are no records currently.</td>
    </tr>
    <% }
    }//end if%>
    <tr colspan="6">
    <td>
    <%//=message%> <input type="submit" name="btnDelete" value="Delete">
    </td>
    </tr>
    </table>
    </form>
    </body>
    </html>
    </a>

  • CR2008, C# and DB2 - Connection Info

    I have a report, originally created in Crystal Reports ver 9, and I have loaded it successfully in CR 2008 (stand alone).  I am able to run that report just fine, it prompts me for the parameter needed for the report, then it promts me for an ODBC data source, which I select, and it runs as expected.
    BTW, this report was generated using a COMMAND to specify the necessary tables and fields for the report instead of selecting specific table and field names (since the list of tables is unavailable via the ODBC link)
    However, in my C# code, I cannot get it to run.  It would appear the information required in the ConnectionOnfo object isn't appropriate for an ODBC datasource, unless I'm over looking something.  So can somebody help me out with setting this up so it runs correctly?
            private void RunReport()
                ReportDocument oRpt = new ReportDocument();
                try
                    oRpt.Load(this._Settings.ReportDirectory + this._ReportFile);
                catch (Exception err)
                    Console.WriteLine(err.Message);
                    Console.ReadKey();
                ConnectionInfo connInfo = new ConnectionInfo();
                // the ODBC DSN on this system is GS30QA, but I'm not sure how to specify this via the ConnectionInfo
                // object... So instead I'll list the actual elements for the cnnection
                connInfo.DatabaseName = "GS2007";
                connInfo.UserID = "secret";
                connInfo.Password = "secret";
                connInfo.ServerName = "PHX-VM-GS30QA1";
                Tables oTables = oRpt.Database.Tables;
                foreach (CrystalDecisions.CrystalReports.Engine.Table oTbl in oTables)
                    TableLogOnInfo tableLogonInfo = oTbl.LogOnInfo;
                    tableLogonInfo.ConnectionInfo = connInfo;
                    oTbl.ApplyLogOnInfo(tableLogonInfo);
                oRpt.SetParameterValue(0, 0);
                // this fails, with an error message of
                // {"Failed to open the connection.\rFailed to open the connection.\nUSPS_ItemizedManifest {DA872B86-5A97-4CF5-B099-2C866D933351}.rpt"}
                oRpt.ExportToDisk(ExportFormatType.PortableDocFormat, @"C:\NET 2.0 Projects\Logicor.GSRouter.Reports\Logicor.GSRouter.Reports\Outputs\test1.pdf");

    Sorry to necro this post, but I was temporarily pulled off this specific project to handle somethig else that was considered a
    higher priority.  Now that I'm finished with that task, it's time to revisit this.  Unfortunately, there's been no progress.
    Also, so everything is clear... When I run this report in the Designer, and press F5 the report promts me to choose an ODBC DSN, and
    I choose this very same one and the report runs.  I just cannot get it to run via the code, it's unable to connect to the DB,
    although I don't know why since it's obvious the report runs in the designer just fine.
    I did as the last post said:
    // name of the 32 bit System DNS on this machine
    connInfo.ServerName = "GSDEMO";
    // name of the actual database
    connInfo.DatabaseName = "GS2007";
    connInfo.UserID = "secret";
    connInfo.Password = "secret";
    Tables oTables = oRpt.Database.Tables;
    foreach (CrystalDecisions.CrystalReports.Engine.Table oTbl in oTables)
        TableLogOnInfo tableLogonInfo = oTbl.LogOnInfo;
        tableLogonInfo.ConnectionInfo = connInfo;
        oTbl.ApplyLogOnInfo(tableLogonInfo);
        // this return false, but I expected that because it's never been able to connect.  I need to know why, which is what I've
        // never been able to discover.
        bool blConnected = oTbl.TestConnectivity();
        Console.WriteLine("Connected: " + blConnected.ToString());
    The error I get this time is
    Failed to open the connection.
    Details:  [Database Vendor Code: -1013 ]
    Failed to open the connection.
    USPS_ItemizedManifest_CR2008 {CD9615AE-3601-4E89-B49B-FB2D54726593}.rpt
    Details:  [Database Vendor Code: -1013 ]
    CrystalDecisions.CrystalReports.Engine.InternalException was unhandled
      Message="Failed to open the connection.\nDetails:  [Database Vendor Code: -1013 ]\rFailed to open the connection.\nUSPS_ItemizedManifest_CR2008 {CD9615AE-3601-4E89-B49B-FB2D54726593}.rpt\nDetails:  [Database Vendor Code: -1013 ]"
      Source="CrystalDecisions.ReportAppServer.DataSetConversion"
      StackTrace:
           at CrystalDecisions.ReportAppServer.ConvertDotNetToErom.ThrowDotNetException(Exception e)
           at CrystalDecisions.ReportSource.EromReportSourceBase.ExportToStream(ExportRequestContext reqContext)
           at CrystalDecisions.CrystalReports.Engine.FormatEngine.ExportToStream(ExportRequestContext reqContext)
           at CrystalDecisions.CrystalReports.Engine.FormatEngine.Export(ExportRequestContext reqContext)
           at CrystalDecisions.CrystalReports.Engine.ReportDocument.ExportToDisk(ExportFormatType formatType, String fileName)
           at Logicor.GSRouter.Reports.MsgParser.RunReport() in C:\NET 2.0 Projects\Logicor.GSRouter.Reports\Logicor.GSRouter.Reports\MsgParser.cs:line 140
           at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
           at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
           at System.Threading.ThreadHelper.ThreadStart()
      InnerException: System.Runtime.InteropServices.COMException
           Message="Failed to open the connection.\nDetails:  [Database Vendor Code: -1013 ]\rFailed to open the connection.\nUSPS_ItemizedManifest_CR2008 {CD9615AE-3601-4E89-B49B-FB2D54726593}.rpt\nDetails:  [Database Vendor Code: -1013 ]"
           Source=""
           ErrorCode=-2147482892
           StackTrace:
                at CrystalDecisions.ReportAppServer.Controllers.ReportSourceClass.Export(ExportOptions pExportOptions, RequestContext pRequestContext)
                at CrystalDecisions.ReportSource.EromReportSourceBase.ExportToStream(ExportRequestContext reqContext)
           InnerException:

  • Oracle 11G,10g and DB2 replication?

    Oracle 11G,10g and DB2 replication?
    =======================================
    We are using Oracle 11gR2. We have a table in Oracle filled with partial data (over 200K+, it may grow to 1M). The rest need to be obtained from DB2. It is not from one DB2 table.
    The DB2 is configured to run Oracle 10g within it. We have given http interface, where we need to supply(Push) the partial data using HTTP_UTIL package for each row, then DB2/Oracle 10g return the result as XML.
    It is a network heavy, slow and not reliable.
    Are we able to replicate tables between Oracle 11g and DB2/oracle 10g?
    We like to leverage the features on 11gR2 effectively.
    I find some interesting folks in this forum.
    Did anyone face such situation?
    I like to know the best approach with good performance options.
    Any idea?
    Thanks in helping.

    qwe16235 wrote:
    The DB2 is configured to run Oracle 10g within it. We have given http interface, where we need to supply(Push) the partial data using HTTP_UTIL package for each row, then DB2/Oracle 10g return the result as XML.
    Any idea?http://en.wikipedia.org/wiki/Rube_Goldberg_machine
    why is DB2 required to produce XML?

  • OWB and DB2

    I have connected Oracle 9i and DB2 v7 and query DB2 in SQL Plus is fine. However, it doesn't for the connection between OWB and DB2.
    Anyone can help?
    Thanks!

    Try the following and use the database link as the source.
    1. Copy inithsodbc.ora to initQA_DB2.ora in $ORACLE_HOME\hs\admin
    HS_FDS_CONNECT_INFO=DNS_NAME_OF_YOUR_CONNECTION
    HS_FDS_TRACE_LEVEL=0
    2. Add the following lines to listener.ora in Oracle server ($ORACLE_HOME\NETWORK\ADMIN)
    (SID_DESC =
    (SID_NAME = QA_DB2)
    (ORACLE_HOME = $ORACLE_HOME)
    (PROGRAM = hsodbc)
    3. Add the following lines to tnsnames.ora in Oracle server ($ORACLE_HOME\NETWORK\ADMIN)
    DB= (DESCRIPTION=
    (ADDRESS=(PROTOCOL=tcp)
    (HOST=localhost)
    (PORT=1521)
    (CONNECT_DATA = (SERVICE_NAME=QA_DB2)
    (HS = OK)
    4. Execute CATalog script for Heterogeneous Services in Oracle server ($ORACLE_HOME\RDBMS\ADMIN\caths.sql)
    5. Create database link
    drop public DATABASE LINK dwh_qa_db2;
    CREATE public DATABASE LINK dwh_qa_db2 CONNECT TO "carlosmo" IDENTIFIED BY "E1Qual" USING 'DB2';
    6. Test the connection
    SELECT *
    FROM SomeTable@dwh_qa_db2

  • Oracle 8i Lite Sqlplus connections

    Hi
    I am trying to run 2 concurrent sqlplus connections in Oracle 8i lite ... it works fine ... if I dont make any changes to database. But Once I commit the changes .... I am not able to make any more connections ....it gives OCA-30017 "Error Loggin on to non-oracle database" and fails connecting to oracle 8i lite. I am using the standard ODBC driver (Oracle Lite) to connect to sqlplus. Please help !!!
    Thanks
    Prabhu.

    I am using Windows 2000 Professional and I am experiencing the same problem. I can connect to the POLITE database from Oracle8 Navigator and Oracle ODBC 32bit Test but not from SQL*Plus. Here is what I see:
    Connected to:
    Oracle Open Client Adapter for ODBC 6.0.5.29.0
    Oracle Lite ORDBMS 4.0.1.0.7
    SQL> connect system/mgr@odbc:POLite
    Server not available or version too low for this feature
    Connected.
    SQL> connect system/mgr
    ERROR:
    ORA-12203: TNS:unable to connect to destination
    Warning: You are no longer connected to ORACLE.
    Should I try to upgrade my Open Client Adapater (OCA)? Could it be something with my PATH? How can I set up the default TNS to connect to POLITE? Any suggestions?
    <BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>Originally posted by Floyd Teter ([email protected]):
    George,
    Try the following host string: ODBC:POLITE
    Lite typically uses the SID of POLite for installation of the default database, so this host string should do the trick. If not, drop me an email and we'll work through it together.
    Hope this helps!
    FMT
    <HR></BLOCKQUOTE>
    null

  • Need to find out a way to figure out how DB2 connect to Oracle and data mirroring etc.

    Hi, Gurus,
    I just take over a project which source is ICOMS as400 db2 database. Seems data mirro CDC is used to replicate from DB2 to oracle.
    I am very new to this datamirror CDC , plus I am new to figure out how db2 connect to oracle, is that through db link or what? or is there tnsnames entry?
    I would like anybody in this forum can point me to the right direction.
    Thanks in advance.

    user9233598, if mirroring/replication from DB2 to Oracle already exists then question is what product is being used?  If the product has already been purchased then I do not think it is very likely that management is going to want to purchase another product so I do not see how extra-cost Golden Gate or other Oracle Gateway features apply if those are not currently in use.  If Golden Gate or the Oracle Transparent Gateway are in use then you already have your answer
    Oracle supports ODBC/JODBC and the replication application on the AS400 likely uses these features or a thick Oracle client as the interface to Oracle.
    HTH -- Mark D Powell --

  • Best Practice to Setup an application to work with both oracle and db2 db

    Hi,
    We have an application that currently supports both oracle and db2 databases . It is currently using JPA with eclipselink as backend mechanism and we want to move to ADFBc as our backend . So what is best practice to do this?
    I came across an old post in https://groups.google.com/forum/#!topic/adf-methodology/UlJZSTu14Io that states to create two different model projects to support oracle and db2 .
    Is this still the standard ? Is there a way that we could work around rather than creating multiple projects?
    How do i get the view controller to work with multiple model projects if this is the case?
    Thank you.

    Thanks for the response .
    The problem is i would have the same schema on both the databases (both in oracle and db2) .
    I don't see a scenario where i want both the application model projects at the same time . What i meant is , Application will either be deployed with Oracle DB or DB2 but not with both on a production environment .
    So is there a way where i just change the connection parameters alone rather having two different models ?
    If i have to use two model projects ,  would it be possible say i built the view controller for Oracle , and use it for DB2 if i make sure the BC objects names are similar between model projects and switch just the model jar based on the deployment environment ?
    -Sam

  • Cannot connect Oracle 11gR2 to DB2 Database

    Hi guys,
    I gotta some issue connecting from Oracle to DB2. The point in, the connection works from Oracle 10G, but does not from 11G. Check it out:
    Oracle 10g:
    Connected to:
    Oracle Database 10g Enterprise Edition Release 10.2.0.5.0 - 64bit Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    SQL> conn test/test
    Connected.
    SQL>
    SQL> create database link db2
    2 connect to user10
    3 identified by user1000
    4 using '(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=167.82.63.98)(PORT=1528))(HS=))';
    Database link created.
    SQL> select count(*) FROM DES.LIST_DEV@DB2;
    COUNT(*)
    231
    ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
    Oracle 11g:
    Connected to:
    Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - 64bit Production
    With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
    Data Mining and Real Application Testing options
    SQL> conn test/test
    Connected.
    SQL>
    SQL> create database link db2
    2 connect to user10
    3 identified by user1000
    4 using '(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=167.82.63.98)(PORT=1528))(HS=))';
    Database link created.
    SQL> select count(*) FROM DES.LIST_DEV@DB2;
    select count(*) FROM DES.LIST_DEV@DB2
    ERROR at line 1:
    ORA-01017: invalid username/password; logon denied
    ORA-02063: preceding line from DB2
    SQL>
    ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
    When connected through Oracle 10 (DBLINK working), DB2 access log shows this information:
    GT8C G4AUTH: (USER10 / ) TCB=(00AC5E88) JOB=(ORAGT8C )
    ICH70001I USER10 LAST ACCESS AT 11:01:14 ON FRIDAY, JULY 29, 2011
    DB2AUTH: AIDLPRIM=(E2C1C4E2C5E24040), AIDLSQL=(4040404040404040)
    DB2AUTH: USERID=(USER10 ), SUBSYS=(GT8C ), STC NAME=(ORAGT8C )
    DB2AUTH: SSAT=(7F5B1840), TCB=(00AC5E88)
    DB2AUTH: SECONDARY ID = (RJ00S )
    Through Oracle 11 (DBLINK not working), these are the logs:
    GT8C G4AUTH: ( / ) TCB=(00AC5628) JOB=(ORAGT8C )
    ICH408I USER( ) GROUP( ) NAME(??? ) 820
    LOGON/JOB INITIATION - USER AT TERMINAL NOT RACF-DEFINED
    IRR012I VERIFICATION FAILED. USER PROFILE NOT FOUND.
    GT8C G4AUTH: VERIFY FAILED R15=(00000004)
    GT8C G4AUTH: ( 00AC5628 / ORAGT8C
    TXM11802I TCP/IP socket #0001(4) closed between 167.82.63.98:1528 and
    10.23.21.166:37691
    Note: The user parameters (user10) is not filled. That's why I got the error 'invalid username/password permission denied'.

    Hi Rahil,
    It is always best to open a new SR instead of adding to an existing one for questions sucha s this, as updates to old threads can be overlooked.
    There are 2 methods you can use to conenct to a DB2 database -
    - Database Gateway for DRDA (DG4DRDA)
    - Database Gateway for ODBC(DG4ODBC)
    There is further information in the following notes available on My Oracle Support -
    Master Note for Oracle Gateway Products (Doc ID 1083703.1)
    Options for Connecting to Foreign Data Stores and Non-Oracle Databases (Doc ID 233876.1)
    Functional Differences Between DG4ODBC and Specific Database Gateways (Doc ID 252364.1)
    Gateway and Generic Connectivity Licensing Considerations (Doc ID 232482.1)
    If you do not have access to My Oracle Support then you will need to contact someone in your organisation to get access, or access the notes for you, as we cannot paste them into OTN.
    You can also check the gateway documentation here -
    http://www.oracle.com/pls/db112/homepage
    Click on 'Information Integration' and then 'Heterogeneous Connectivity'
    Regards,
    Mike

  • SQLJ connection exception in oracle 8i and jdk 1.5

    This is the code through which i am trying to extract current date from oracle database and print Helloworld
    // import required packages
    import java.sql.Date;
    import java.sql.SQLException;
    import oracle.sqlj.runtime.Oracle;
    public class HelloWorld {
    public static void main(String [] args) {
    java.sql.Date current_date;
    try {
    // connect to the database
    Oracle.connect(
    "jdbc:oracle:thin:@localhost:1521:orcl",
    "student",
    "student"
    // get the current date from the database
    #sql { SELECT sysdate INTO :current_date FROM dual };
    // display message
    System.out.println("Hello World! The current date is " +
    current_date);
    } catch ( SQLException e ) {
    System.err.println("SQLException " + e);
    } finally {
    try {
    // disconnect from the database
    Oracle.close();
    } catch ( SQLException e ) {
    System.err.println("SQLException " + e);
    } // end of main()
    this is the error
    unexpected error occurred...
    java.lang.ExceptionInInitializerError
         at sqlj.translator.Translator.addUnit(Translator.java:117)
         at sqlj.translator.Main.translate(Main.java:112)
         at sqlj.translator.Main.runTranslation(Main.java:92)
         at sqlj.translator.Main.runTranslation(Main.java:85)
         at sqlj.tools.Sqlj.statusMain(Sqlj.java:280)
         at sqlj.tools.Sqlj.main(Sqlj.java:125)
    Caused by: java.lang.NullPointerException
         at sqlj.framework.ClassFileReader.attribute_info(ClassFileReader.java:326)
         at sqlj.framework.ClassFileReader.readClass(ClassFileReader.java:224)
         at sqlj.framework.ClassFileReader.describeClass(ClassFileReader.java:62)
         at sqlj.framework.ClassFileReader.getDeclaringClass(ClassFileReader.java:146)
         at sqlj.framework.JSClass$ClassWrapper.getDeclaringClass(JSClass.java:1649)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1496)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1545)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1552)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1507)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1518)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1533)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1539)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1508)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1545)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1552)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1507)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1545)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1552)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1507)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1518)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1533)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1539)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1508)
         at sqlj.framework.JSClass.resolveIfNonNull(JSClass.java:1513)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1493)
         at sqlj.framework.JSClass.resolveIfNonNull(JSClass.java:1513)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1493)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1534)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1539)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1508)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1545)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1552)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1507)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1518)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1533)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1539)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1508)
         at sqlj.framework.JSClass.resolveIfNonNull(JSClass.java:1513)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1493)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1545)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1552)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1507)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1518)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1494)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1518)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1533)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1539)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1508)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1518)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1533)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1539)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1508)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1534)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1539)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1508)
         at sqlj.framework.JSClass.resolveIfNonNull(JSClass.java:1513)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1495)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1534)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1539)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1508)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1518)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1494)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1534)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1539)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1508)
         at sqlj.framework.JSClass.resolveIfNonNull(JSClass.java:1513)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1493)
         at sqlj.framework.JSClass.resolveIfNonNull(JSClass.java:1513)
         at sqlj.framework.JSClass.resolveClassReferences(JSClass.java:1493)
         at sqlj.framework.JSClass.reflectSystemClass(JSClass.java:1340)
         at sqlj.framework.JSClass.<clinit>(JSClass.java:49)
         ... 6 more
    HelloWorld.sqlj: Error: Exception caught:
    Total 1 error.

    SQLJ 8i with jdk1.5?
    Please try SQLJ 10.2 with jdk1.4.

Maybe you are looking for

  • Disharging with USB, Freezing on Sync, Hard Drive noise on Line Out

    I have been dealing with three issues with my 60GB iPod click wheel with color display (Photo). The first is something that slowly creeped in, which is hard drive noise that is audible through the line out when the iPod is charging in a dock. I'd lik

  • I can not find my external hard drive...

    The time machine is not working. How do I find my external hard drive and find my backup files? Perhaps this has to do with the fact that I lost power the other day and my router is not working... A different question.. Is this related?

  • IPhoto 6.0.5 + Mac OS 10.4.8 won't import photo from Canon 350D

    Hello, I am using a Canon 350D and iPhoto since 18 months. Since my latest set of upgrades, iPhoto opens correctly when I plug my camera in but the Import process is not starting. I upgraded simultanously Mac OS X to 10.4.8 and iPhoto to 6.0.5 (316)

  • Mobileme gallery - pictures in wrong order?

    Hi, I recently made a Mobileme gallery in iPhoto and published it. About 407 pictures and 2 movies. It published, then I changed a few things, republished - and then the order of some of the pictures changed. Just for the **** of it, I deleted 4 pict

  • Use iPhone as an external hard drive?

    I am going to be purchasing an iPhone in the near future, and I was wondering, does the iPhone have an external hard drive mode? What I mean is, on the iPod, I can turn on "use as external hard drive" as a means of transferring files (i.e. word docum