How to use Oracle rather then Cloudscape

Discussions

EJB design: How to use Oracle rather then Cloudscape

  1. How to use Oracle rather then Cloudscape (3 messages)

    dear friends,

       can u pl. tell me how to use oracle 8i in Beans(CMP) as DataBase rather Cloudscape DB


    thankQ

    -das
  2. dear friends,   can u pl. tell me how to use oracle 8i in Beans(CMP) as DataBase rather Cloudscape DBthankQ-das
    Well first you need to create the DB pool using the web-based admin interface. If you have already installed the app server and started it then you should have access to your local app server using port 4848:

    http://localhost:4848

    Then you should configure you database connection and pool through that interface. You also need to declare the connection in your ejb-jar.xml and the sun-ejb-jar.xml.
    This process requires that you know how to work with the app server. Refer to the on-line documentation to learn more as how to create you connection pools and using them in your applications.

  3.   mr/Mrs Rasoul Hajikhani ,


       Can u explain in detail



  4. It depends what J2EE container you are using ?

    1) First define a DataSource ( connection pool) for Oracle database

    For example, if you are using OC4J, you have to create the DataSources as follows:
    <data-source
    class="com.evermind.sql.DriverManagerDataSource"
    name="OracleDS2"
    location="jdbc/OracleCoreDS2"
    xa-location="jdbc/xa/OracleXADS2"
    ejb-location="jdbc/OracleDS"
    connection-driver="oracle.jdbc.driver.OracleDriver"
    username="ab"
    password="ab"
    url="jdbc:oracle:thin:@localhost:1521:db"
    inactivity-timeout="30"
    />


    2) Then specify the JNDI location for the DataSource in your vendor deployment descriptor of your entity bean to use that datasource e.g.

    <entity-deployment name="EmployeeBean" max-tx-retries="0" location="cmpapp/EmployeeBean" table="EMP" data-synchronization- data-source="jdbc/OracleDS" >

    Hope this helps ..

    -Debu Panda

    http://radio.weblogs.com/0135826/