Error while reading 'META-INF/weblogic-cmp-rdbms-jar.xml

Hi,
I am getting an error running appc. I am upgrading from wl 7 to wl 8.1. ejbc works
fine on wl 7. Anyone seen this before?
[J2EE:160121]Errors encountered while compiling module 'e:\dev\xstatic\tmp\xstatic_Intermediate.jar':
[EJB:011017]Error while reading 'META-INF/weblogic-cmp-rdbms-jar.xml'. The error
was:
java.lang.NullPointerException
at weblogic.ejb20.cmp.rdbms.finders.ExprWHERE.init_method()V(ExprWHERE.java:47)
at weblogic.ejb20.cmp.rdbms.finders.BaseExpr.init(Lweblogic.ejb20.cmp.rdbms.finders.QueryContext;Lweblogic.ejb20.cmp.rdbms.finders.QueryNode;)V(BaseExpr.java:230)
at weblogic.ejb20.cmp.rdbms.finders.ExprROOT.init_method()V(ExprROOT.java:89)
at weblogic.ejb20.cmp.rdbms.finders.BaseExpr.init(Lweblogic.ejb20.cmp.rdbms.finders.QueryContext;Lweblogic.ejb20.cmp.rdbms.finders.QueryNode;)V(BaseExpr.java:230)
at weblogic.ejb20.cmp.rdbms.finders.QueryContext.generateQuery()V(QueryContext.java:91)
at weblogic.ejb20.cmp.rdbms.finders.Finder.computeSQLQuery(Lweblogic.ejb20.cmp.rdbms.RDBMSBean;)V(Finder.java:1002)
at weblogic.ejb20.cmp.rdbms.RDBMSBean.generateFinderSQLStatements(Ljava.util.Iterator;)V(RDBMSBean.java:2692)
at weblogic.ejb20.cmp.rdbms.Deployer.readTypeSpecificData(Ljava.io.InputStream;Ljava.lang.String;)V(Deployer.java:479)
at weblogic.ejb20.persistence.PersistenceType.setTypeSpecificFile(Lweblogic.ejb20.interfaces.EntityBeanInfo;Lweblogic.ejb20.persistence.spi.CMPDeployer;)V(PersistenceType.java:483)
at weblogic.ejb20.persistence.PersistenceType.setupDeployer(Lweblogic.ejb20.interfaces.EntityBeanInfo;Ljava.io.File;Lweblogic.utils.Getopt2;Lweblogic.utils.jars.VirtualJarFile;)Lweblogic.ejb20.persistence.spi.CMPDeployer;(PersistenceType.java:414)
at weblogic.ejb20.deployer.CMPInfoImpl.setup(Ljava.io.File;Lweblogic.utils.Getopt2;Lweblogic.utils.jars.VirtualJarFile;)V(CMPInfoImpl.java:113)
at weblogic.ejb20.ejbc.EJB20CMPCompiler.generatePersistenceSources(Lweblogic.ejb20.interfaces.EntityBeanInfo;Lweblogic.utils.jars.VirtualJarFile;)Ljava.util.List;(EJB20CMPCompiler.java:64)
at weblogic.ejb20.ejbc.EJBCompiler.doCompile(Ljava.util.Collection;Lweblogic.utils.jars.VirtualJarFile;)V(EJBCompiler.java:245)
at weblogic.ejb20.ejbc.EJBCompiler.compileEJB(Lweblogic.utils.classloaders.GenericClassLoader;Lweblogic.management.configuration.EJBComponentMBean;Lweblogic.management.descriptors.toplevel.EJBDescriptorMBean;Lweblogic.utils.jars.VirtualJarFile;Lweblogic.j2ee.valid
ation.ModuleValidationInfo;Lweblogic.ejb20.ejbc.VersionHelper;Ljava.util.Collection;)V(EJBCompiler.java:468)
at weblogic.ejb20.ejbc.EJBCompiler.compileEJB(Lweblogic.utils.classloaders.GenericClassLoader;Lweblogic.utils.jars.VirtualJarFile;Lweblogic.j2ee.validation.ModuleValidationInfo;)V(EJBCompiler.java:387)
at weblogic.appc.compileEJB(Lweblogic.utils.classloaders.GenericClassLoader;Lweblogic.utils.jars.VirtualJarFile;Ljava.io.File;Lweblogic.j2ee.validation.ModuleValidationInfo;)V(appc.java:735)
at weblogic.appc.compileEJB()V(appc.java:709)
at weblogic.appc.compileInput()V(appc.java:446)
at weblogic.appc.runBody()V(appc.java:167)
at weblogic.utils.compiler.Tool.run([Ljava.lang.String;)V(Tool.java:146)
at weblogic.utils.compiler.Tool.run()V(Tool.java:103)
at weblogic.appc.main([Ljava.lang.String;)V(appc.java:961)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

It is a bug for the EJB container to respond with an NPE.
(It's been fixed in v9 Beta, and it might be fixed in an 8.1 service pack but I can't recall off the top of my head). At any rate, I'm pretty sure that an EJB QL query with an empty WHERE clause will cause this. I would look for a query that ends in ' WHERE'.
-thorick

Similar Messages

  • Question about weblogic-cmp-rdbms-jar.xml

    WinNT 4.0 SP6, Weblogic 5.10
    In the online documents, it says:
    ---- digest from the online documents ----
    The following example finds all the EJBs in a table. It uses the
    sample finder method signature:
    public Enumeration findAllAccounts()
    throws FinderException, RemoteException
    The sample <finder> stanza uses an empty WLQL string:
    <finder>
    <method-name>findAllAccounts</method-name>
    <finder-query></finder-query>
    </finder>
    ---- End of digest ----
    However I implement it in my sample EJB, call findAllAccounts in the
    client JSP file, get a SQLException about "null after where".
    How can i solve this problem?
    Thanks in advance,
    Paul Shen
    Email: [email protected]
    WWW: shensr.8m.com

    In the DOCTYPE declaration, replace "weblogic-cmp-rdbms-jar" with
    "weblogic-rdbms-jar".
    Bob
    "Jason" <[email protected]> wrote in message
    news:[email protected]..
    >
    When I deploy my bean I get the following error:
    While reading META-INF/weblogic-cmp-rdbms-jar.xml, the EntityEJB's pers
    istence layer failed to deploy. The error was:
    Error in descriptor line 7: Document root element "weblogic-rdbms-jar",must ma
    tch DOCTYPE root "weblogic-cmp-rdbms-jar".
    atweblogic.ejb20.ejbc.EJBCompiler.compileEJB(EJBCompiler.java:302)
    >
    >
    Here is my deployment descriptor: (weblogic-cmp-rdbms-jar.xml)
    <?xml version="1.0"?>
    <!DOCTYPE weblogic-cmp-rdbms-jar PUBLIC
    '-//BEA Systems, Inc.//DTD WebLogic 6.0.0 EJB RDBMS Persistence//EN'
    'http://www.bea.com/servers/wls600/dtd/weblogic-rdbms20-persistence-600.dtd'
    >
    >
    <weblogic-rdbms-jar>
    <weblogic-rdbms-bean>
    <ejb-name>MessageEJB</ejb-name>
    <data-source-name>ora8lplxPoolDataSource</data-source-name>
    <table-name>Messages</table-name>
    <field-map>
    <cmp-field>msg_id</cmp-field>
    <dbms-column>msg_id</dbms-column>
    </field-map>
    <field-map>
    <cmp-field>msg</cmp-field>
    <dbms-column>msg</dbms-column>
    </field-map>
    <field-map>
    <cmp-field>msg_date</cmp-field>
    <dbms-column>msg_date</dbms-column>
    </field-map>
    </weblogic-rdbms-bean>
    </weblogic-rdbms-jar>

  • Problem with weblogic-cmp-rdbms-jar.xml

    While using ANT by apache to create a deployable EAR file for my application i
    created the weblogic-cmp-rdbms-jar.xml file with the following DOCTYPE header
    <!DOCTYPE weblogic-rdbms-bean PUBLIC '-//BEA Systems, Inc.//DTD WebLogic 6.0.0
    EJB RDBMS20 Persistence//EN' 'http://www.bea.com/servers/wls600/dtd/weblogic-rdbms20-persistence-600.dtd'>
    when i go for ejbc following error is displayed
    [java] ERROR: Error from ejbc: Error while reading 'META-INF/weblogic-cmp-rdbms-jar.xml'.
    The error was:
    [java] weblogic.xml.process.ProcessorFactoryException: The public id, "-//BEA
    Systems, Inc.//DTD WebLogic 6.0.0 EJB RDBMS20 Persistence//EN", specified in the
    XML document is invalid. Use one of the following valid public ids:
    [java] "-//BEA Systems, Inc.//DTD WebLogic 5.1.0 EJB RDBMS Persistence//EN"
    [java] "-//BEA Systems, Inc.//DTD WebLogic 6.0.0 EJB 1.1 RDBMS Persistence//EN"
    [java]
    [java] at weblogic.xml.process.ProcessorFactory.getProcessor(ProcessorFactory.java:239)
    [java] at weblogic.ejb20.cmp11.rdbms.Deployer.parseXMLFile(Deployer.java:293)
    [java] at weblogic.ejb20.cmp11.rdbms.Deployer.readTypeSpecificData(Deployer.java:358)
    [java] at weblogic.ejb20.persistence.PersistenceType.setTypeSpecificFile(PersistenceType.ja
    va:482)
    [java] at weblogic.ejb20.persistence.PersistenceType.setupDeployer(PersistenceType.java:406
    [java] at weblogic.ejb20.deployer.CMPInfoImpl.setup(CMPInfoImpl.java:139)
    [java] at weblogic.ejb20.ejbc.EJB11CMPCompiler.generatePersistenceSources(EJB11CMPCompiler.
    java:61)
    [java] at weblogic.ejb20.ejbc.EJBCompiler.compileEJB(EJBCompiler.java:233)
    [java] at weblogic.ejbc20.runBody(ejbc20.java:360)
    [java] at weblogic.utils.compiler.Tool.run(Tool.java:79)
    [java] at weblogic.ejbc.main(ejbc.java:21)
    [java]
    [java] ERROR: ejbc found errors
    BUILD FAILED
    i have created the Doctype header after refering to the documentation available
    at http://edocs.bea.com/wls/docs61///////ejb/EJB_reference.html
    please help me as i am not able to find out the exact problem. i have also applied
    the ejb2.0 patch available for 6.0 which is supposed to enable the ejb2.0 related
    features
    Any help will be really appreciated
    thanx in advance
    Daljit

    Are you trying to make an EJB 1.1 CMP bean or an EJB 2.0 CMP bean.
    It looks like you have an EJB 1.1 ejb-jar.xml, but have requested an EJB 2.0 cmp descriptor.
    Take a look at examples/ejb/basic/containerManaged and ejb20/basic/containerManaged for the 2 examples.
    -- Rob
    Daljit Chauhan wrote:
    While using ANT by apache to create a deployable EAR file for my application i
    created the weblogic-cmp-rdbms-jar.xml file with the following DOCTYPE header
    <!DOCTYPE weblogic-rdbms-bean PUBLIC '-//BEA Systems, Inc.//DTD WebLogic 6.0.0
    EJB RDBMS20 Persistence//EN' 'http://www.bea.com/servers/wls600/dtd/weblogic-rdbms20-persistence-600.dtd'>
    when i go for ejbc following error is displayed
    [java] ERROR: Error from ejbc: Error while reading 'META-INF/weblogic-cmp-rdbms-jar.xml'.
    The error was:
    [java] weblogic.xml.process.ProcessorFactoryException: The public id, "-//BEA
    Systems, Inc.//DTD WebLogic 6.0.0 EJB RDBMS20 Persistence//EN", specified in the
    XML document is invalid. Use one of the following valid public ids:
    [java] "-//BEA Systems, Inc.//DTD WebLogic 5.1.0 EJB RDBMS Persistence//EN"
    [java] "-//BEA Systems, Inc.//DTD WebLogic 6.0.0 EJB 1.1 RDBMS Persistence//EN"
    [java]
    [java] at weblogic.xml.process.ProcessorFactory.getProcessor(ProcessorFactory.java:239)
    [java] at weblogic.ejb20.cmp11.rdbms.Deployer.parseXMLFile(Deployer.java:293)
    [java] at weblogic.ejb20.cmp11.rdbms.Deployer.readTypeSpecificData(Deployer.java:358)
    [java] at weblogic.ejb20.persistence.PersistenceType.setTypeSpecificFile(PersistenceType.ja
    va:482)
    [java] at weblogic.ejb20.persistence.PersistenceType.setupDeployer(PersistenceType.java:406
    [java] at weblogic.ejb20.deployer.CMPInfoImpl.setup(CMPInfoImpl.java:139)
    [java] at weblogic.ejb20.ejbc.EJB11CMPCompiler.generatePersistenceSources(EJB11CMPCompiler.
    java:61)
    [java] at weblogic.ejb20.ejbc.EJBCompiler.compileEJB(EJBCompiler.java:233)
    [java] at weblogic.ejbc20.runBody(ejbc20.java:360)
    [java] at weblogic.utils.compiler.Tool.run(Tool.java:79)
    [java] at weblogic.ejbc.main(ejbc.java:21)
    [java]
    [java] ERROR: ejbc found errors
    BUILD FAILED
    i have created the Doctype header after refering to the documentation available
    at http://edocs.bea.com/wls/docs61///////ejb/EJB_reference.html
    please help me as i am not able to find out the exact problem. i have also applied
    the ejb2.0 patch available for 6.0 which is supposed to enable the ejb2.0 related
    features
    Any help will be really appreciated
    thanx in advance
    Daljit

  • Weblogic-cmp-rdbms-jar.xml for One-To-Many unidirectional relationship

    hi,
    I am trying to create a simple cmp One-To-Many unidirectional relationship and deploy the same in weblogic. Can someone help me with the weblogic-cmp-rdbms-jar.xml. Am attaching the weblogic-cmp-rdbms-jar. xml tht i am using as also the corresponding ejb-jar.xml. Pls. note tht i want a unidirectional relationship here. one i am tryng However i get this error:
    Error while reading 'META-INF/weblogic-cmp-rdbms-jar.xml'. The error was: Role 'Supplier supplies Products' of relationship 'Product Supplier' contains an invalid key-column value of 'productID'. The key-column must specify a primary key column in the related bean. However, there is no primary key column named 'productID' defined in the related bean 'ProductEJB' or else 'productID' is not being recognized due to case mismatch. My weblogic-cmp-rdbms-jar
    <?xml version="1.0"?>
    <!DOCTYPE weblogic-rdbms-jar PUBLIC '-//BEA Systems, Inc.//DTD WebLogic 8.1.0 EJB RDBMS Persistence//EN' 'http://www.bea.com/servers/wls810/dtd/weblogic-rdbms-jar.dtd'>
    <weblogic-rdbms-jar>
    <weblogic-rdbms-bean>
         <ejb-name>SupplierEJB</ejb-name>
         <data-source-name>RJDataSource</data-source-name>
         <table-map>
               <table-name>AA_Supplier</table-name>
               <field-map>
                     <cmp-field>supplierID</cmp-field>
                     <dbms-column>supplierID</dbms-column>
               </field-map>
               <field-map>
                    <cmp-field>name</cmp-field>
                    <dbms-column>name</dbms-column>
               </field-map>
         </table-map>
    </weblogic-rdbms-bean>
    <weblogic-rdbms-bean>
           <ejb-name>ProductEJB</ejb-name>
           <data-source-name>RJDataSource</data-source-name>
           <table-map>
                 <table-name>AA_Product</table-name>
                 <field-map>
                      <cmp-field>productID</cmp-field>
                      <dbms-column>productid</dbms-column>
                 </field-map>
                 <field-map>
                      <cmp-field>description</cmp-field>
                      <dbms-column>description</dbms-column>
                 </field-map>
                 <field-map>
                      <cmp-field>basePrice</cmp-field>
                      <dbms-column>baseprice</dbms-column>
                 </field-map>
                <field-map>
                      <cmp-field>name</cmp-field>
                      <dbms-column>name</dbms-column>
                 </field-map>
                 <field-map>
                     <cmp-field>supplierID</cmp-field>
                       <dbms-column>supplierID</dbms-column>
                 </field-map>
            </table-map>
    </weblogic-rdbms-bean>
    <weblogic-rdbms-relation>
         <relation-name>Product Supplier</relation-name>
         <weblogic-relationship-role>
              <relationship-role-name>Supplier supplies Products</relationship-role-name>
              <relationship-role-map>
                   <column-map>
                        <foreign-key-column>supplierID</foreign-key-column>
                        <key-column>productID</key-column>
                   </column-map>
              </relationship-role-map>
         </weblogic-relationship-role>
         <weblogic-relationship-role>
              <relationship-role-name>Product supplied by Supplier</relationship-role-name>
              <relationship-role-map>
              <column-map>
                   <foreign-key-column>products</foreign-key-column>
                   <key-column>supplierID</key-column>
              </column-map>
              </relationship-role-map>
         </weblogic-relationship-role>
    </weblogic-rdbms-relation>
    </weblogic-rdbms-jar> My ejb-jar.xml
    <?xml version="1.0"?>
    <!DOCTYPE ejb-jar PUBLIC '-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN' 'http://java.sun.com/dtd/ejb-jar_2_0.dtd'>
    <ejb-jar>
         <enterprise-beans>
         <entity>
              <ejb-name>SupplierEJB</ejb-name>
              <home>com.tpt.practice.entityBeans.cmp.product.relationship.SupplierHome</home>
              <remote>com.tpt.practice.entityBeans.cmp.product.relationship.Supplier</remote>
              <ejb-class>com.tpt.practice.entityBeans.cmp.product.relationship.SupplierEJB</ejb-class>
              <persistence-type>Container</persistence-type>
              <prim-key-class>java.lang.String</prim-key-class>
              <reentrant>False</reentrant>
              <cmp-version>2.x</cmp-version>
              <abstract-schema-name>AA_Supplier</abstract-schema-name>
              <cmp-field>
                   <field-name>supplierID</field-name>
              </cmp-field>
              <cmp-field>
                   <field-name>name</field-name>
              </cmp-field>
              <primkey-field>supplierID</primkey-field>
              <ejb-ref>
                        <ejb-ref-name>ProducEJB</ejb-ref-name>
                        <ejb-ref-type>Entity</ejb-ref-type>
                        <home>com.tpt.practice.entityBeans.cmp.product.ProductHome</home>
                        <remote>com.tpt.practice.entityBeans.cmp.product.Product</remote>
                        <ejb-link>ProductEJB#ProductEJB.jar</ejb-link>
              </ejb-ref>
              <query>
                   <query-method>
                        <method-name>findByName</method-name>
                        <method-params>
                             <method-param>java.lang.String</method-param>
                        </method-params>
                   </query-method>
                   <ejb-ql>
                        <![CDATA[SELECT OBJECT(a) FROM AA_Supplier AS a WHERE a.name =
                        ?1]]>
                   </ejb-ql>
              </query>
              <query>
                   <query-method>
                        <method-name>findAllSuppliers</method-name>
                        <method-params>
                        </method-params>
                   </query-method>
                   <ejb-ql>
                        <![CDATA[SELECT OBJECT(a) FROM AA_Supplier AS a WHERE a.supplierID
                        IS NOT NULL]]>
                   </ejb-ql>
              </query>
         </entity>
         <entity>
              <ejb-name>ProductEJB</ejb-name>
              <home>com.tpt.practice.entityBeans.cmp.product.relationship.ProductHome</home>
              <remote>com.tpt.practice.entityBeans.cmp.product.relationship.Product</remote>
              <local-home>com.tpt.practice.entityBeans.cmp.product.relationship.ProductLocalHome</local-home>
              <local>com.tpt.practice.entityBeans.cmp.product.relationship.ProductLocal</local>
              <ejb-class>com.tpt.practice.entityBeans.cmp.product.relationship.ProductEJB</ejb-class>
              <persistence-type>Container</persistence-type>
              <prim-key-class>com.tpt.practice.entityBeans.cmp.product.relationship.ProductPK</prim-key-class>
              <reentrant>False</reentrant>
              <cmp-version>2.x</cmp-version>
              <abstract-schema-name>AA_Product</abstract-schema-name>
              <cmp-field>
                   <field-name>productID</field-name>
              </cmp-field>
              <cmp-field>
                   <field-name>name</field-name>
              </cmp-field>
              <cmp-field>
                   <field-name>description</field-name>
              </cmp-field>
              <cmp-field>
                   <field-name>basePrice</field-name>
              </cmp-field>
              <cmp-field>
                   <field-name>supplierID</field-name>
              </cmp-field>
              <primkey-field>productID</primkey-field>
              <query>
                   <query-method>
                        <method-name>findByName</method-name>
                        <method-params>
                             <method-param>java.lang.String</method-param>
                        </method-params>
                   </query-method>
                   <ejb-ql>
                        <![CDATA[SELECT OBJECT(a) FROM AA_Product AS a WHERE a.name =
                        ?1]]>
                   </ejb-ql>
              </query>
              <query>
                   <query-method>
                        <method-name>findByDescription</method-name>
                        <method-params>
                             <method-param>java.lang.String</method-param>
                        </method-params>
                   </query-method>
                   <ejb-ql>
                        <![CDATA[SELECT OBJECT(a) FROM AA_Product AS a WHERE a.description
                        = ?1]]>
                   </ejb-ql>
              </query>
              <query>
                   <query-method>
                        <method-name>findByBasePrice</method-name>
                        <method-params>
                             <method-param>double</method-param>
                        </method-params>
                   </query-method>
                   <ejb-ql>
                        <![CDATA[SELECT OBJECT(a) FROM AA_Product AS a WHERE a.basePrice =
                        ?1]]>
                   </ejb-ql>
              </query>
              <query>
                   <query-method>
                        <method-name>findExpensiveProducts</method-name>
                        <method-params>
                             <method-param>double</method-param>
                        </method-params>
                   </query-method>
                   <ejb-ql>
                        <![CDATA[SELECT OBJECT(a) FROM AA_Product AS a WHERE a.basePrice >
                        ?1]]>
                   </ejb-ql>
              </query>
              <query>
                   <query-method>
                        <method-name>findCheapProducts</method-name>
                        <method-params>
                             <method-param>double</method-param>
                        </method-params>
                   </query-method>
                   <ejb-ql>
                        <![CDATA[SELECT OBJECT(a) FROM AA_Product AS a WHERE a.basePrice <
                        ?1]]>
                   </ejb-ql>
              </query>
              <query>
                   <query-method>
                        <method-name>findAllProducts</method-name>
                        <method-params>
                        </method-params>
                   </query-method>
                   <ejb-ql>
                        <![CDATA[SELECT OBJECT(a) FROM AA_Product AS a WHERE a.productID
                        IS NOT NULL]]>
                   </ejb-ql>
              </query>
         </entity>
         </enterprise-beans>
         <relationships>
         <ejb-relation>
              <ejb-relation-name>Product Supplier</ejb-relation-name>
              <ejb-relationship-role>
                   <ejb-relationship-role-name>Supplier supplies Products</ejb-relationship-role-name>
                   <multiplicity>One</multiplicity>
                   <relationship-role-source>
                        <ejb-name>SupplierEJB</ejb-name>
                   </relationship-role-source>
                   <cmr-field>
                        <cmr-field-name>products</cmr-field-name>
                        <cmr-field-type>java.util.Collection</cmr-field-type>
                   </cmr-field>
              </ejb-relationship-role>
              <ejb-relationship-role>
                   <ejb-relationship-role-name>Product supplied by Supplier</ejb-relationship-role-name>
                   <multiplicity>Many</multiplicity>
                   <relationship-role-source>
                        <ejb-name>ProductEJB</ejb-name>
                   </relationship-role-source>
              </ejb-relationship-role>
         </ejb-relation>
         </relationships>
         <assembly-descriptor>
              <container-transaction>
              <method>
                   <ejb-name>SupplierEJB</ejb-name>
                   <method-intf>Remote</method-intf>
                   <method-name>*</method-name>
              </method>
              <trans-attribute>Required</trans-attribute>
              </container-transaction>
         </assembly-descriptor>
    </ejb-jar>

    I think u r some confusion with productID and SuppliedID . primary key of one column( productId ) can be a foreign key of other table colum( SuppliedID). but foreign key( SuppliedID) can not be a primary key of second table .u declared SuppliedId as primary key . so ur mapping is incorrect.

  • Weblogic-cmp-rdbms-jar.xml

    When I deploy my bean I get the following error:
    While reading META-INF/weblogic-cmp-rdbms-jar.xml, the Entity EJB's pers
    istence layer failed to deploy. The error was:
    Error in descriptor line 7: Document root element "weblogic-rdbms-jar", must ma
    tch DOCTYPE root "weblogic-cmp-rdbms-jar".
    at weblogic.ejb20.ejbc.EJBCompiler.compileEJB(EJBCompiler.java:302)
    Here is my deployment descriptor: (weblogic-cmp-rdbms-jar.xml)
    <?xml version="1.0"?>
    <!DOCTYPE weblogic-cmp-rdbms-jar PUBLIC
    '-//BEA Systems, Inc.//DTD WebLogic 6.0.0 EJB RDBMS Persistence//EN'
    'http://www.bea.com/servers/wls600/dtd/weblogic-rdbms20-persistence-600.dtd'>
    <weblogic-rdbms-jar>
    <weblogic-rdbms-bean>
    <ejb-name>MessageEJB</ejb-name>
    <data-source-name>ora8lplxPoolDataSource</data-source-name>
    <table-name>Messages</table-name>
    <field-map>
    <cmp-field>msg_id</cmp-field>
    <dbms-column>msg_id</dbms-column>
    </field-map>
    <field-map>
    <cmp-field>msg</cmp-field>
    <dbms-column>msg</dbms-column>
    </field-map>
    <field-map>
    <cmp-field>msg_date</cmp-field>
    <dbms-column>msg_date</dbms-column>
    </field-map>
    </weblogic-rdbms-bean>
    </weblogic-rdbms-jar>

    In the DOCTYPE declaration, replace "weblogic-cmp-rdbms-jar" with
    "weblogic-rdbms-jar".
    Bob
    "Jason" <[email protected]> wrote in message
    news:[email protected]..
    >
    When I deploy my bean I get the following error:
    While reading META-INF/weblogic-cmp-rdbms-jar.xml, the EntityEJB's pers
    istence layer failed to deploy. The error was:
    Error in descriptor line 7: Document root element "weblogic-rdbms-jar",must ma
    tch DOCTYPE root "weblogic-cmp-rdbms-jar".
    atweblogic.ejb20.ejbc.EJBCompiler.compileEJB(EJBCompiler.java:302)
    >
    >
    Here is my deployment descriptor: (weblogic-cmp-rdbms-jar.xml)
    <?xml version="1.0"?>
    <!DOCTYPE weblogic-cmp-rdbms-jar PUBLIC
    '-//BEA Systems, Inc.//DTD WebLogic 6.0.0 EJB RDBMS Persistence//EN'
    'http://www.bea.com/servers/wls600/dtd/weblogic-rdbms20-persistence-600.dtd'
    >
    >
    <weblogic-rdbms-jar>
    <weblogic-rdbms-bean>
    <ejb-name>MessageEJB</ejb-name>
    <data-source-name>ora8lplxPoolDataSource</data-source-name>
    <table-name>Messages</table-name>
    <field-map>
    <cmp-field>msg_id</cmp-field>
    <dbms-column>msg_id</dbms-column>
    </field-map>
    <field-map>
    <cmp-field>msg</cmp-field>
    <dbms-column>msg</dbms-column>
    </field-map>
    <field-map>
    <cmp-field>msg_date</cmp-field>
    <dbms-column>msg_date</dbms-column>
    </field-map>
    </weblogic-rdbms-bean>
    </weblogic-rdbms-jar>

  • Why weblogic-cmp-rdbms-jar.xml.old gets created in Weblogic 7?

    Hi all,
    I use the build.bat file for creating the jar file
    build.bat
    ==========
    mkdir build build\META-INF
    copy *.xml build\META-INF
    @REM Compile EJB classes into the build directory (jar preparation)
    javac -d build *.java
    @REM Make a EJB jar file, including XML deployment descriptors
    cd build
    jar cv0f std_ejb_accountcmp.jar META-INF ejb
    cd ..
    @REM Run EJBC on jar file
    java -classpath %WL_HOME%/lib/weblogic.jar weblogic.ejbc -convertDDs -verbose -keepgenerated -compiler javac build\std_ejb_accountcmp.jar d:\ejb_accountcmp.jar
    =============================================================
    Any ideas why when u unjar the jar file created for deployment in Weblogic 7.0, it creates an old copy of the xml files used
    For example :
    weblogic-ejb-jar.xml has weblogic-ejb-jar.xml.old
    ejb-jar.xml has ejb-jar.xml.old
    Why does it replace the weblogic-cmp-rdbms-jar.xml to weblogic-cmp-rdbms-jar.xml.old?
    Rgds,
    Seetesh

    Hi Indra,
    Thanks for ur post.
    I have now renamed the weblogic-cmp-rdbms-jar.xml to weblogic-cmp20-rdbms-jar.xml and made the changes in the weblogic-ejb-jar.xml file in the type-storage parameter.
    Now after executing the foll cmd
    java ..... weblogic.ejbc old.jar new.jar
    The new.jar file contains the generated stub/skeleton along with the additional old files for the 2 xml's ejb-jar.xml and weblogic-ejb-jar.xml.
    Using the Weblogic builder utility, while opening the new.jar file, it discards the old xml deployment descriptors and creates new ones in its place.
    Cld u give me some hints on using the Deployment tool? I use it to deploy the new.jar file.
    Rgds,
    Seetesh

  • Tools for generating weblogic-cmp-rdbms-jar.xml files

    Hi All:
    I am using Weblogic 8.1 sp6 and MyEclipse 5.1.
    Does anybody knows if weblogic 8.1 provides a wizard or tool or some product that will help you generate the
    weblogic-cmp-rdbms-jar.xml and webloigc-ejb-jar.xml files if given the ejb-jar.xml, the home, remote and bean classes and the database server information.
    The reason, I am asking this is because if you're using Hibernate, there is a hibernate tool that will generate the hbm.xml and persistence classes given a particular database information.
    I was wondering if there is the same thing in ejb development with weblogic 8.1 sp6?
    Yours,
    Desperate

    I think u r some confusion with productID and SuppliedID . primary key of one column( productId ) can be a foreign key of other table colum( SuppliedID). but foreign key( SuppliedID) can not be a primary key of second table .u declared SuppliedId as primary key . so ur mapping is incorrect.

  • Creating weblogic-cmp-rdbms-jar.xml from JDeveloper 10g

    Hi
    is any one aware if I can create the weblogic-cmp-rdbms-jar.xml from the Jdeveloper 10g. I know that it definitely does not have this deployment discriptor in the list.
    Is there any other way of creating this via JDeveloper.
    if not would it be a good feature to have?

    A schema for weblogic-cmp-rdbms-jar.xml may be registered and an XML document based on the schema generated.

  • Transaction Isolation Levels in weblogic-cmp-rdbms-jar.xml

    Hi All,
    Iam using ejb 1.1 specification with weblogic 5.1. We can set the transaction
    isolation levels for the methods in the
    weblogic-ejb-jar.xml. There is also a provision for setting this isolation level
    in the weblogic-cmp-rdbms-jar.xml. Now is there any difference between setting
    the isolation levels in these two ways.
    Help me asap.

    The CMP setting has been deprecated. You can set it for all types of
    EJBs in the weblogic-ejb-jar.xml
    -- Rob
    chandru wrote:
    Hi All,
    Iam using ejb 1.1 specification with weblogic 5.1. We can set the transaction
    isolation levels for the methods in the
    weblogic-ejb-jar.xml. There is also a provision for setting this isolation level
    in the weblogic-cmp-rdbms-jar.xml. Now is there any difference between setting
    the isolation levels in these two ways.
    Help me asap.

  • Ejb-jar.xml中的EJB QL和weblogic-cmp-rdbms-jar.xml中的WLQL

    我想问一下,在ejb-jar.xml文件中用EJB QL查询语言定义了相应的EJB QL查询语句后,在weblogic-cmp-rdbms-jar.xml文件中还需不需要用wlql语言来定义相应的查询语句呀?

    在Weblogic6.0中,如果你需要利用EJB2.0的EJBQL语言所不提供的
    ORDERBY排序功能,那么这时候可以在weblogic-cmp-rdbms-jar.xml中用WLQL覆盖它,一般情况下,在ejb-jar.xml中声明一个EJBQL方法就可以了,WLQL可有可无。

  • How can I generate weblogic-cmp-rdbms-jar.xml

    Hello furum does any one know how I can generate
    weblogic-cmp-rdbms-jar.xml by using C:\jdev9031 ?
    all the helps are welcome.I am working on entityBeans realtion.
    thanks

    I think u r some confusion with productID and SuppliedID . primary key of one column( productId ) can be a foreign key of other table colum( SuppliedID). but foreign key( SuppliedID) can not be a primary key of second table .u declared SuppliedId as primary key . so ur mapping is incorrect.

  • Column-map in weblogic-cmp-rdbms-jar.xml

    Hi,
    How to specify column-map for the following database tables:
    Table1: id,col2,col3. Primary key - id.
    Table2: m_id,description,col4,col5. Primay key - (m_id,col4).
    The relationship I specified is table1-has-many-table2. This is a 1 to m relation
    and
    Table1.id = Table2.m_id.
    I specified the following column-map
    <column-map>
    <foreign-key-column>m_id</foreign-key-column>
    <key-column>id</key-column>
    </column-map>
    But the server is throwing an exception that all the columns in table2 should
    me mapped.
    But in this case, I can join the tables with just id only. What should I specify
    for col4 map?.
    I can just reverse the mapping, but I am trying to test the boundaries of weblogic
    server.
    Is this case handled in weblogic server implementation?.
    I am testing relationship-role-map for ejb2.0 on weblogic server8.1 beta version.
    Thanks,
    Sathish

    Hello Sathish,
    Glad to help! Have a wonderful week.
    Best regards,
    Ryan LeCompte
    [email protected]
    http://www.louisiana.edu/~rml7669
    "Sathish Kandacharam" <[email protected]> wrote:
    >
    Hi Ryan,
    Thanks alot. That example helped alot.
    Thanks,
    Sathish
    "Ryan LeCompte" <[email protected]> wrote:
    Hello Sathish,
    Please refer to the sample code that comes packaged with BEA WebLogic
    Server for
    examples of how the weblogic-cmp-rdbms-jar.xml file should look forall
    of the
    various relationships. In particular, look at the Bands example.
    Best regards,
    Ryan LeCompte
    [email protected]
    http://www.louisiana.edu/~rml7669
    "Sathish Kandacharam" <[email protected]> wrote:
    Hi,
    How to specify column-map for the following database tables:
    Table1: id,col2,col3. Primary key - id.
    Table2: m_id,description,col4,col5. Primay key - (m_id,col4).
    The relationship I specified is table1-has-many-table2. This is
    a
    1 to m relation
    and
    Table1.id = Table2.m_id.
    I specified the following column-map
    <column-map>
    <foreign-key-column>m_id</foreign-key-column>
    <key-column>id</key-column>
    </column-map>
    But the server is throwing an exception that all the columns intable2
    should
    me mapped.
    But in this case, I can join the tables with just id only. Whatshould
    I specify
    for col4 map?.
    I can just reverse the mapping, but I am trying to test the boundaries
    of weblogic
    server.
    Is this case handled in weblogic server implementation?.
    I am testing relationship-role-map for ejb2.0 on weblogic server8.1
    beta version.
    Thanks,
    Sathish

  • Weblogic-cmp-jar.xml vs weblogic-cmp-rdbms-jar.xml

    We've recently upgraded from WLS 6.1 to 8.1.
    Can anyone clarify the difference between <b>weblogic-cmp-jar.xml</b> and <b>weblogic-cmp-rdbms-jar.xml</b>?
    The weblogic-cmp-rdbms-jar.xml format we've been using is essentially just a list of data base elements, but we may have been under-utilizing it.
    The weblogic-cmp-jar.xml seems more complex and useful.
    Thanks.

    You can reference the edoc at:
    http://e-docs.bea.com/wls/docs100/ejb/DDreference-cmp-jar.html
    http://e-docs.bea.com/wls/docs100/ejb/ejb11.html

  • Entity Finder mothod takes run time String. How can I specify in CDATA of the weblogic-cmp-ejb-jar.xml

    Hi everyone,
    I have an CMP bean which has findByName(String). During deployment of the ejb
    I tell the bean use the WLQL such as
    (like string%), but I would like to pass the name when the user enter in the text
    box of the .html page then the user click on search, the servlet is called and
    process using ejb technique. If I specified (like Fre%) in the ejb despcriptor
    for one particular case( such as looking for all Fred's), it will not work for
    the user enters smith.
    for example: user enter: Fre in the text box.
    I would like to have the bean do the query for me like:
    --> select * from user where lastName like Fre%
    If I cannot tell in the CDATA field, does that mean I have to use BMP to write
    query that takes the name.
    Please help,
    Thanks in advance.

    Thanks Jim,
    I did exactly like in the example (like Name $0) Name is my cmp field, but this
    time it always returns one entity (same entity )regardless what I entered to search
    by name. So that means it did not take the parameter that defined in <find-param>
    of the weblogic-cmp-rdbm-jar.xml. Do you have any suggestion or idea to overcome
    this problem.
    Thanks Jim,
    Tom
    Jim Weaver <[email protected]> wrote:
    >
    Tom
    You can use like with a String parameter in WLQL. There is an example
    in our
    documentation at
    http://www.weblogic.com/docs51/classdocs/API_ejb/EJB_environment.html#1022700
    Thanks
    Jim
    Tom wrote:
    Hi everyone,
    I have an CMP bean which has findByName(String). During deploymentof the ejb
    I tell the bean use the WLQL such as
    (like string%), but I would like to pass the name when the user enterin the text
    box of the .html page then the user click on search, the servlet iscalled and
    process using ejb technique. If I specified (like Fre%) in the ejbdespcriptor
    for one particular case( such as looking for all Fred's), it will notwork for
    the user enters smith.
    for example: user enter: Fre in the text box.
    I would like to have the bean do the query for me like:
    --> select * from user where lastName like Fre%
    If I cannot tell in the CDATA field, does that mean I have to use BMPto write
    query that takes the name.
    Please help,
    Thanks in advance.Content-Description: Card for Jim Weaver
    begin:vcard
    n:Weaver;Jim
    x-mozilla-html:FALSE
    org:BEA Systems Inc.
    adr:;;.;;;;
    version:2.1
    email;internet:[email protected]
    title:Developer Relations Engineer
    fn:Jim Weaver
    end:vcard

  • Please check this ejb-jar.xml, weblogic-ejb-jar.xml,weblogic-cmp-rdbms.xml

    i am getting a classcast exception.My Stateless and stateful session bean works
    fine .. problem only with Entity bean. Please check these xml files and let me
    know if i have missed anything.
    ejb-jar.xml
    <?xml version="1.0"?>
    <!DOCTYPE ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans
    2.0//EN" "http://java.sun.com/dtd/ejb-jar_2_0.dtd">
    <ejb-jar>
    <enterprise-beans>
    <entity>
    <ejb-name>stores</ejb-name>
    <home>Ejb.Stores.storesHome</home>
    <remote>Ejb.Stores.storesRemote</remote>
    <ejb-class>Ejb.Stores.storesBean</ejb-class>
    <persistence-type>Container</persistence-type>
    <prim-key-class>java.lang.String</prim-key-class>
    <reentrant>False</reentrant>
    <cmp-version>2.x</cmp-version>
    <abstract-schema-name>storesBean</abstract-schema-name>
    <cmp-field>
    <field-name>productId</field-name>
    </cmp-field>
    <cmp-field>
    <field-name>descrip</field-name>
    </cmp-field>
    <cmp-field>
    <field-name>price</field-name>
    </cmp-field>
    <primkey-field>productId</primkey-field>
    <query>
    <query-method>
    <method-name>findPriceGreaterThan</method-name>
    <method-params>
    <method-param>double</method-param>
    </method-params>
    </query-method>
    <ejb-ql>
    <![CDATA[SELECT OBJECT(a) FROM storesBean AS a WHERE a.price > ?1]]>
    </ejb-ql>
    </query>
    </entity>
    </enterprise-beans>
    <assembly-descriptor>
    <container-transaction>
    <method>
    <ejb-name>stores</ejb-name>
         <method-name>*</method-name>
    </method>
    <trans-attribute>Required</trans-attribute>
    </container-transaction>
    </assembly-descriptor>
    </ejb-jar>
    ------------- end of ejb-ar.xml---------------------
    weblogic-jar.xml
    <?xml version="1.0"?>
    <!DOCTYPE weblogic-ejb-jar PUBLIC "-//BEA Systems, Inc.//DTD WebLogic 6.0.0 EJB//EN"
    "http://www.bea.com/servers/wls600/dtd/weblogic-ejb-jar.dtd" >
    <weblogic-ejb-jar>
    <weblogic-enterprise-bean>
    <ejb-name>stores</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>storesEntity</jndi-name>
    </weblogic-enterprise-bean>
    </weblogic-ejb-jar>
    ------------- end of weblogic-jar.xml----------
    weblogic-cmp-rdbms-jar.xml
    <!DOCTYPE weblogic-rdbms-jar PUBLIC '-//BEA Systems, Inc.//DTD WebLogic 6.0.0
    EJB RDBMS Persistence//EN' 'http://www.bea.com/servers/wls600/dtd/weblogic-rdbms20-persistence-600.dtd'>
    <weblogic-rdbms-jar>
    <weblogic-rdbms-bean>
    <ejb-name>stores</ejb-name>
    <data-source-name>sqlTX</data-source-name>
    <table-name>ProductEJBTable</table-name>
    <field-map>
    <cmp-field>productId</cmp-field>
    <dbms-column>productId</dbms-column>
    </field-map>
    <field-map>
    <cmp-field>descrip</cmp-field>
    <dbms-column>descrip</dbms-column>
    </field-map>
    <field-map>
    <cmp-field>price</cmp-field>
    <dbms-column>price</dbms-column>
    </field-map>
    </weblogic-rdbms-bean>
    <create-default-dbms-tables>false</create-default-dbms-tables>
    </weblogic-rdbms-jar>
    ---------------- end of weblogic-cmp-rdbms-jar.xml----------
    Do i have to mention the connection Pool name anywhere .. My connection Pool name
    is sql7Pool and my datasource name which i have mentioned is sqlTx. I am using
    Sql server 7. I am deploying a jar file(not a war file) and accessng the EJB through
    a Servlet. Please any help would definitely be appreciated.
    Cheers
    Ashish.

    I thought you were getting a class cast exception but the stack trace shows
    a NullPointerException on line 38 of your servlet code. I am not sure if the
    code that you have attached is the complete code or just snippets of your
    complete code. Anyways, counting 38 lines in the code you attached points to
    the line "mr =
    mh.create(request.getParameter("login"),request.getParameter("name"));"
    which could be because "mh" is null. Can you verify "mh" is not null and
    also "objRef" is not null.
    Attaching the stack trace for ClassCastException would be useful.
    -- Anand
    "Ashish Suvarna" <[email protected]> wrote in message
    news:[email protected]...
    >
    Hey Anand,
    Thanks for your reply. I have attached the StackTrace,Servlet code andmy
    location and settings of my servlet .
    This is the StackTrace which i get :
    pl.java:265)
    atweblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubIm
    pl.java:200)
    atweblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppSe
    rvletContext.java:2495)
    atweblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestIm
    pl.java:2204)
    at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139)
    at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)
    before create
    java.lang.NullPointerException
    at trialweblogic.webServlet.doGet(webServlet.java:38)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    atweblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubIm
    pl.java:265)
    atweblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubIm
    pl.java:200)
    atweblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppSe
    rvletContext.java:2495)
    atweblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestIm
    pl.java:2204)
    at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139)
    at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)
    -------------- end of StackTrace---------------------
    My Servlet Code is
    package trialweblogic;
    import javax.servlet.*;
    import javax.servlet.http.*;
    import java.io.*;
    import java.util.*;
    import java.sql.*;
    import javax.naming.InitialContext;
    import javax.rmi.PortableRemoteObject;
    import javax.ejb.ObjectNotFoundException;
    import javax.ejb.DuplicateKeyException;
    import javax.ejb.EJBException;
    import java.rmi.RemoteException;
    import java.rmi.Remote;
    import trialweblogic.*;
    public class webServlet extends HttpServlet {
    masterHome mh;
    masterRemote mr;
    OutputStream out;
    private static final String CONTENT_TYPE = "text/html";
    public void init(ServletConfig config) throws ServletException {
    super.init(config);
    public void doGet(HttpServletRequest request, HttpServletResponseresponse)
    throws ServletException, IOException {
    response.setContentType(CONTENT_TYPE);
    PrintWriter out = response.getWriter();
    // out = response.getOutputStream();
    try{
    InitialContext ic = new InitialContext();
    Object objRef = ic.lookup("masterBeanJNDI");
    mh =(masterHome)PortableRemoteObject.narrow(objRef,masterHome.class);
    >
    mr =mh.create(request.getParameter("login"),request.getParameter("name"));
    out.println("after create");
    }catch(Exception ex){
    ex.printStackTrace();
    public void destroy() {
    --------- end of servlet--------------
    I am using Weblogic 6.1. I have included the following in my web.xml filewhich
    is located atC:\bea\wlserver6.1\config\examples\applications\examplesWebApp\WEB-INF
    >
    >
    <servlet>
    <servlet-name>webServlet</servlet-name>
    <servlet-class>trialweblogic.webServlet</servlet-class>
    </servlet>
    <servlet-mapping>
    <servlet-name>webServlet</servlet-name>
    <url-pattern>/webServlet/*</url-pattern>
    </servlet-mapping>
    My Servlet is located atC:\bea\wlserver6.1\config\examples\applications\examplesWebApp\WEB-INF\class
    es\trialweblogic\
    folder. In this folder i also have the supporting files (home,remote &bean tooo).
    >
    >
    I call this servlet when te user submits the info from a JSP page.
    Hope this info helps in solving my problem. Do i have to mention theconnection
    Pool name anywhere in the xml descriptor or am i missing anything here. iguess
    Connection Pool name is not required since we are mentioning the JNDI namein
    the xml descriptor. Bye for now.Awaiting your reply.
    Cheers
    Ashish.
    "Anand Byrappagari" <[email protected]> wrote:
    It is unlikely that your xml descriptors can cause class cast exceptions.
    How did you install the servlet? Can you attach the servlet code that
    might
    help. Also complete stack trace of the exceptions would be helpful.
    -- Anand
    "Ashish Suvarna" <[email protected]> wrote in message
    news:[email protected]...
    Hi Anand,
    Thanks for quic reply.Hey i am using weblogic6.1. I am Not usinga WAR
    and
    ear file.I have created a jar file and deployed it.now i have createda
    servlet
    to access entity bean.Is a war file neccessary for accesing an entitybean
    through
    Servlet or JSP ???I am using sql server 7. The error that it givesis -----
    java.lang.ClassCastException: Cannot narrow remote object<br>
    "inside lookup method aaaaaaa" java.lang.NullPointerException. <br>
    Hope to get ur reply soon. in another entity bean i am getting thiserror ---
    java.lang.ClassCastException:
    weblogic.jdbc.common.internal.RmiDataSource
    .. I
    can't understand wots this error. I feel i am missing something inmy xml
    descriptor.
    Bye for now.
    Cheers
    Ashish.
    "Anand Byrappagari" <[email protected]> wrote:
    Can you attach the stack trace for the exception? Also please describe
    you
    environment - are the war and jar files installed separately? Are
    they
    composed into a ear? Also when are you getting a classcast exception?
    -- Anand
    "Ashish Suvarna" <[email protected]> wrote in message
    news:[email protected]...
    i am getting a classcast exception.My Stateless and stateful sessionbean
    works
    fine .. problem only with Entity bean. Please check these xml filesand
    let me
    know if i have missed anything.
    ejb-jar.xml
    <?xml version="1.0"?>
    <!DOCTYPE ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD EnterpriseJavaBeans
    2.0//EN" "http://java.sun.com/dtd/ejb-jar_2_0.dtd">
    <ejb-jar>
    <enterprise-beans>
    <entity>
    <ejb-name>stores</ejb-name>
    <home>Ejb.Stores.storesHome</home>
    <remote>Ejb.Stores.storesRemote</remote>
    <ejb-class>Ejb.Stores.storesBean</ejb-class>
    <persistence-type>Container</persistence-type>
    <prim-key-class>java.lang.String</prim-key-class>
    <reentrant>False</reentrant>
    <cmp-version>2.x</cmp-version>
    <abstract-schema-name>storesBean</abstract-schema-name>
    <cmp-field>
    <field-name>productId</field-name>
    </cmp-field>
    <cmp-field>
    <field-name>descrip</field-name>
    </cmp-field>
    <cmp-field>
    <field-name>price</field-name>
    </cmp-field>
    <primkey-field>productId</primkey-field>
    <query>
    <query-method>
    <method-name>findPriceGreaterThan</method-name>
    <method-params>
    <method-param>double</method-param>
    </method-params>
    </query-method>
    <ejb-ql>
    <![CDATA[SELECT OBJECT(a) FROM storesBean AS a WHERE
    a.price> >> >>> >> >?1]>
    </ejb-ql>
    </query>
    </entity>
    </enterprise-beans>
    <assembly-descriptor>
    <container-transaction>
    <method>
    <ejb-name>stores</ejb-name>
    <method-name>*</method-name>
    </method>
    <trans-attribute>Required</trans-attribute>
    </container-transaction>
    </assembly-descriptor>
    </ejb-jar>
    ------------- end of ejb-ar.xml---------------------
    weblogic-jar.xml
    <?xml version="1.0"?>
    <!DOCTYPE weblogic-ejb-jar PUBLIC "-//BEA Systems, Inc.//DTD
    WebLogic
    6.0.0 EJB//EN"
    "http://www.bea.com/servers/wls600/dtd/weblogic-ejb-jar.dtd" >
    <weblogic-ejb-jar>
    <weblogic-enterprise-bean>
    <ejb-name>stores</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>storesEntity</jndi-name>
    </weblogic-enterprise-bean>
    </weblogic-ejb-jar>
    ------------- end of weblogic-jar.xml----------
    weblogic-cmp-rdbms-jar.xml
    <!DOCTYPE weblogic-rdbms-jar PUBLIC '-//BEA Systems, Inc.//DTD
    WebLogic
    6.0.0
    EJB RDBMS Persistence//EN'
    'http://www.bea.com/servers/wls600/dtd/weblogic-rdbms20-persistence-600.dt
    d
    <weblogic-rdbms-jar>
    <weblogic-rdbms-bean>
    <ejb-name>stores</ejb-name>
    <data-source-name>sqlTX</data-source-name>
    <table-name>ProductEJBTable</table-name>
    <field-map>
    <cmp-field>productId</cmp-field>
    <dbms-column>productId</dbms-column>
    </field-map>
    <field-map>
    <cmp-field>descrip</cmp-field>
    <dbms-column>descrip</dbms-column>
    </field-map>
    <field-map>
    <cmp-field>price</cmp-field>
    <dbms-column>price</dbms-column>
    </field-map>
    </weblogic-rdbms-bean>
    <create-default-dbms-tables>false</create-default-dbms-tables>
    </weblogic-rdbms-jar>
    ---------------- end of weblogic-cmp-rdbms-jar.xml----------
    Do i have to mention the connection Pool name anywhere .. My
    connection
    Pool name
    is sql7Pool and my datasource name which i have mentioned is sqlTx.I am
    using
    Sql server 7. I am deploying a jar file(not a war file) and accessngthe
    EJB through
    a Servlet. Please any help would definitely be appreciated.
    Cheers
    Ashish.

Maybe you are looking for

  • How to embed .jpg in MP3

    Hi. I am seeking a way to embed .jpg-files to MP3-files. I know that logic has some options on how to embed ID3 tags to mp3-files, but I cannot find any way to embed .jpg-files. Basically, I just recorded an album which I want to put on my webside, s

  • How to select last record or first record value in a formula?

    Post Author: d111 CA Forum: General I am using a query in a report that in addition to other columns, has a column of month labels like: There are no unique identifiers or sequence fields that can be used.   There is only 4 columns: the label and 3 p

  • IWeb '09 and Google Analytics

    So, Apple finally released the feature I've been waiting years for - the ability to upload to FTP in iWeb '09. This is really awesome because iWeb can upload changes to a site only instead of having to export the site to my hard drive then upload the

  • Unauthorized Payment - please Refund

    Hi Skpype team, I just noticed in my banking account that you withdrew $ 0.1 on 7/12/13. I did not authorize this payment, and also this payment does not show up under "Purchase history" or anywhere else in my Skype account. Could you please contact

  • Theres an opportunity to RESIZE all linked images to 100% of the frame?

    Theres some third party plugins, but i dont find one which works well and support layered psd for example. i think its a basic function and it should have an native way to do that. thanks a lot.