Hi chris,
According to your instructions I had created DataSource as well as Connection pool in administrative console. But I am getting the error:Unable to deploy EJB: CabinBean from cabin.jar:
The DataSource with the JNDI name: cabinPool could not be located. Please ensure
that the DataSource has been deployed successfully and that the JNDI name in yo
ur EJB Deployment descriptor is correct.
I am using MsAccess 2000 and the name of table is cabin the odbc driver name is also cabin but the name of database is db1.
I copy paste the connection pool data which I had created:
Name: cabinPool
URL: jdbc
dbc:cabin
Driver Classname: sun.jdbc.odbc.JdbcOdbcDriver
Properties
(key=value): user=none
password=none
ACLName:
Password: change...
Open
String Password: change...
Here , I copy paste Data Source elements:
Name: TxSource
JNDI Name: togetherPool
Pool Name: cabinPool
Enable Two-Phase Commit
Row Prefetch Enabled
Row Prefetch Size: 48
Stream Chunk Size: 256 bytes
Now I copy paste my weblogic-cmp-rdbms-jar xml file:
<!DOCTYPE weblogic-rdbms-jar PUBLIC
'-//BEA Systems, Inc.//DTD WebLogic 6.0.0 EJB RDBMS Persistence//EN'
'C://Sun/weblogic/ejb20/cmp/rdbms/weblogic-rdbms20-persistence-600.dtd'>
<weblogic-rdbms-jar>
<weblogic-rdbms-bean>
<ejb-name>CabinBean</ejb-name>
<data-source-name>cabinPool</data-source-name>
<table-name>Cabin</table-name>
<field-map>
<cmp-field>id</cmp-field>
<dbms-column>ID</dbms-column>
</field-map>
<field-map>
<cmp-field>ship</cmp-field>
<dbms-column>SHIP_ID</dbms-column>
</field-map>
<field-map>
<cmp-field>bedCount</cmp-field>
<dbms-column>BED_COUNT</dbms-column>
</field-map>
<field-map>
<cmp-field>name</cmp-field>
<dbms-column>NAME</dbms-column>
</field-map>
<field-map>
<cmp-field>deckLevel</cmp-field>
<dbms-column>DECK_LEVEL</dbms-column>
</field-map>
</weblogic-rdbms-bean>
<create-default-dbms-tables>True</create-default-dbms-tables>
</weblogic-rdbms-jar>
Here, Is the copy paste of weblogic-ejb-jar.xml:
<!DOCTYPE weblogic-ejb-jar PUBLIC "-//BEA Systems, Inc.//DTD WebLogic 6.0.0 EJB//EN" "C://Sun/weblogic/ejb20/dd/xml/weblogic600-ejb-jar.dtd">
<weblogic-ejb-jar>
<weblogic-enterprise-bean>
<ejb-name>CabinBean</ejb-name>
<entity-descriptor>
<persistence>
<persistence-type>
<type-identifier>WebLogic_CMP_RDBMS</type-identifier>
<type-version>6.0</type-version>
<type-storage>META-INF/weblogic-cmp-rdbms-jar.xml</type-storage>
</persistence-type>
<persistence-use>
<type-identifier>WebLogic_CMP_RDBMS</type-Identifier>
<type-version>6.0</type-version>
</persistence-use>
</persistence>
</entity-descriptor>
<jndi-name>cabin.CabinHome</jndi-name>
</weblogic-enterprise-bean>
</weblogic-ejb-jar>
Please, tell me where is the actual problem. Also tell me that in my DD is my jndi-name and data-source-name elements are ok or not ?.
thank you