Question on Persistence (Entity Beans, Hibernate, JDBC)

Hi everybody!
Until now, I have read a lot about persistence in the J2EE-sector, but I am still confused about which technology to used in my case.
I hope, that maybe you can give me some hints, by telling me which technology is good or bad regarding my requirements:
I want to build a customer- and order-management system fullfilling the following requirements:
1. The client is a Java application, the server is a JBOSS 4.0.1
2. The databasa scheme exists already and I'm not allowed to change it.
Some data, that logically belongs together and which shall be presented together to the client is distributed over 2 database tables.
3. The user cannot just create new and view data, but will also edit existing data quite often.
4. The user can assign products to an order. Often, there will be more than 1000 products assigned to an order, which will be presented to the user as a table (e.g. JTable). The user can then edit each cell of that 1000-row table, which of course will lead to an update in the db.
5. The user can also assign customers to a specific role in an order-process. On the other hand, each customer can make many orders.
So, we have a n:m relation here with the db-tables Customer, Order, OrderCustomer.
6. A complex search functionality has to be implemented, where the db-query is created dynamically at runtime.
7. The application is a multi-user application (about 10 users). It will be very rare, that users will work on the same data at the same time, but it might happen.
8. The database type (SAP DB) will not be changed in the near future.
With these 8 requirements in mind, I dealed a lot with EntityBeans, Hibernate and JDBC with SesseionBeans during the last 2 weeks.
Until now, I came to the following conclusions.
Hibernate is too slow. That'S bad, for data is edited very often and sometimes I want to edit just a single cell in 1000-row table.
Hibernate's biggest advantage - that it makes your application independent of the database type - is not even required (see point 8).
JDBC with SessioBeans: Very fast (I tried a simple query and it was about 10 times faster than Hibernate).
The disadvantage is, that I have to take care about all the transaction, concurrency control etc. things.
If I use JDBC, I want to do it that way: A SessionFacade accesses a DAO-object which executes the DB-query and returns the result to the SessionFacade which in the last step will pass the result to the client.
Entity Beans: I am completely confused with Entity Beans.
I read a lot about the CompositeEntity-Pattern for BMP. But on sun's J2EE Pattern page (http://java.sun.com/blueprints/corej2eepatterns/Patterns/CompositeEntity.html)
they said, that it's just useful when using the EJB 1.1 specification, because from EJB 2.0. the container or whatever will take care about lazy loading and store optimization.
So, from EJB 2.0. you should prefer using CMP-Beans with Container Managed Relationships (CMR), but as I heard, the dependent objects cannot be accessed and changed by the client when using CMPBeans with CMR.
However, a simple DB/Entity-mapping will not work in my case, because as mentioned above, there are thousands of products from the db to be managed at the same time. So here, I thought, the Composite pattern with its lazy loading strategy would be useful.
Furthermore, I have an n:m relationship in my database scheme, which is not trivial to map to entity beans. And don't forget that some related data is spread over 2 databse tables.
To sum it up, it would be very nice if some of you could clarify this perisistence nightmare, especially some clarification about if and how to use EntityBeans when having n:m relationships, editing data a lot, managing lots of table rows at once and having related data distributed over 2 database tables.
So, which technology would you prefer with the 8 requirements in mind? Hibernate, Entity Beans or JDBC with SessionBeans? Or would you prefer a mixed solution?
Thanx for every hint.
Regards,
egon

Here the requested information about the test:
Goal:
Find all customers, who's branches have the String "Branch" in their name.
Both times, a simple client accesses the same SessionBean in a JBOSS-Container.
This Bean has 2 methods. One accesses the DB via Hibernate (executeCriteria), the other one via JDBC (executeCriteriaJDBC).
The code to count the seconds of computation is as follows:
long startTime = System.currentTimeMillis();
List customerList = bean.executeCriteria(dc);
System.out.println("Hibernate: "+((System.currentTimeMillis()-startTime)/1000.0f)+" sek");
startTime = System.currentTimeMillis();
List customerListJDBC = bean.executeCriteriaJDBC(query);
System.out.println("JDBC: "+((System.currentTimeMillis()-startTime)/1000.0f)+" sek");
HIBERNATE:
CODE:
Branch Branch = new Branch();
Branch.setName("%Branch%");
Example example = Example.create(Branch);     
DetachedCriteria dc = DetachedCriteria.forClass(Customer.class)
.createCriteria("branches").add(example.enableLike()).setResultTransformer(Criteria.DISTINCT_ROOT_ENTITY);
QUERY:
select
        this_.UUID as UUID1_1_,
        this_.NAME as NAME1_1_,
        this_.CUSTOMERNO as CUSTOMERNO1_1_,
        this_.SHORTDESC as SHORTDESC1_1_,
        this_.LONGDESC as LONGDESC1_1_,
        this_.TAXNUMBER as TAXNUMBER1_1_,
        this_.SALESTAXID as SALESTAXID1_1_,
        this_.ACCOUNTHOLDER as ACCOUNTH8_1_1_,
        this_.BANKACCOUNT as BANKACCO9_1_1_,
        this_.BANKCODE as BANKCODE1_1_,
        this_.BANKNAME as BANKNAME1_1_,
        this_.AREA1TEXT as AREA12_1_1_,
        this_.AREA2TEXT as AREA13_1_1_,
        this_.AREA3TEXT as AREA14_1_1_,
        this_.AREA4TEXT as AREA15_1_1_,
        this_.AREA5TEXT as AREA16_1_1_,
        this_.CH_UUID as CH17_1_1_,
        this_.REFTEXT1 as REFTEXT18_1_1_,
        this_.REFTEXT2 as REFTEXT19_1_1_,
        this_.REFTEXT3 as REFTEXT20_1_1_,
        branch1_.UUID as UUID0_0_,
        branch1_.NAME as NAME0_0_,
        branch1_.ILN as ILN0_0_,
        branch1_.BRANCHID as BRANCHID0_0_,
        branch1_.SHORTDESC as SHORTDESC0_0_,
        branch1_.LONGDESC as LONGDESC0_0_,
        branch1_.BAGSRECEIVED as BAGSRECE7_0_0_,
        branch1_.CUSTOMER_UUID as CUSTOMER8_0_0_
    from
        CUSTOMER this_,
        BRANCH branch1_
    where
        this_.UUID=branch1_.CUSTOMER_UUID
        and (
            branch1_.NAME like ?
RESULT:
Customername: Customer_A
Customername: Customer_F
Customername: Customer_D
Customername: Customer_R
Customername: Customer_S
TIME:
Hibernate: 1.343 sek
JDBC:
QUERY:
Select distinct c.* from Customer c, Branch b where b.id=b.Customer_id and b.name like '%Branch%'
// After getting the result of the query: Create a list of Customer-objects. Set all attributes of each Customer-object.
RESULT:
Customername: Customer_R
Customername: Customer_A
Customername: Customer_S
Customername: Customer_D
Customername: Customer_F
TIME:
JDBC: 0.125 sek
The Customer.hbm.xml (auto-generated in Eclipse with Middlegen)
<?xml version="1.0"?>
<!DOCTYPE hibernate-mapping PUBLIC
    "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
    "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd" >
<hibernate-mapping>
<!--
    Created by the Middlegen Hibernate plugin 2.2
    http://boss.bekk.no/boss/middlegen/
    http://www.hibernate.org/
-->
<class
    name="hibernate.hibernate.Customer"
    table="CUSTOMER"
    lazy="false"
>
    <id
        name="uuid"
        type="java.lang.String"
        column="UUID"
    >
        <generator class="assigned" />
    </id>
    <property
        name="name"
        type="java.lang.String"
        column="NAME"
        length="100"
    />
    <property
        name="customerno"
        type="java.lang.Integer"
        column="CUSTOMERNO"
        length="5"
    />
    <property
        name="shortdesc"
        type="java.lang.String"
        column="SHORTDESC"
        length="50"
    />
    <property
        name="longdesc"
        type="java.lang.String"
        column="LONGDESC"
        length="100"
    />
    <property
        name="taxnumber"
        type="java.lang.String"
        column="TAXNUMBER"
        length="50"
    />
    <property
        name="salestaxid"
        type="java.lang.String"
        column="SALESTAXID"
        length="50"
    />
    <property
        name="accountholder"
        type="java.lang.String"
        column="ACCOUNTHOLDER"
        length="50"
    />
    <property
        name="bankaccount"
        type="java.lang.String"
        column="BANKACCOUNT"
        length="50"
    />
    <property
        name="bankcode"
        type="java.lang.String"
        column="BANKCODE"
        length="50"
    />
    <property
        name="bankname"
        type="java.lang.String"
        column="BANKNAME"
        length="50"
    />
    <property
        name="area1text"
        type="java.lang.String"
        column="AREA1TEXT"
        length="50"
    />
    <property
        name="area2text"
        type="java.lang.String"
        column="AREA2TEXT"
        length="50"
    />
    <property
        name="area3text"
        type="java.lang.String"
        column="AREA3TEXT"
        length="50"
    />
    <property
        name="area4text"
        type="java.lang.String"
        column="AREA4TEXT"
        length="50"
    />
    <property
        name="area5text"
        type="java.lang.String"
        column="AREA5TEXT"
        length="50"
    />
    <property
        name="chUuid"
        type="java.lang.String"
        column="CH_UUID"
        length="50"
    />
    <property
        name="reftext1"
        type="java.lang.String"
        column="REFTEXT1"
        length="50"
    />
    <property
        name="reftext2"
        type="java.lang.String"
        column="REFTEXT2"
        length="50"
    />
    <property
        name="reftext3"
        type="java.lang.String"
        column="REFTEXT3"
        length="50"
    />
    <!-- Associations -->
    <!-- bi-directional one-to-many association to Branch -->
    <set
        name="branches"
        lazy="true"
        inverse="true"
       cascade="all"
    >
        <key>
            <column name="CUSTOMER_UUID" />
        </key>
        <one-to-many
            class="hibernate.hibernate.Branch"
        />
    </set>
</class>
</hibernate-mapping>So, seems to me like Hibernate is also getting the data from the Branch-Table related to each Customer. Maybe this is the reason, why Hibernate is slower.
But as you can see in the mapping-File of the customer, I wanted Branches to be lazy loaded.
Do you have any ideas, why Hibernate is so much slower? Any hints for optimizing that code?
Do you have any further tricks to optimize Hibernate? Unfortunately I am not allowed to make changes at the database, so I cannot e.g. set indices for optimization.
However, I�m a Hibernate-Newbie. In fact, I just made this test and was very disappointed about its result, so I didn�t keep on working with Hibernate.
But maybe you can proof me, that Hibernate is a good choice. If so, do you have any good resources (links, books) that help working with Hibernate in connection with JBOSS, describe how to map n:m relationships, show how to work with large results and so forth?
Thanx for help,
egon

Similar Messages

  • Container Managed Persistence entity bean relationship fields

    I want to ask something that until now still confuse. Did Relationship fields in Container Managed Persistence entity beans declare , inside Database table or only Persistence fields .
    If Relationship fields not declare inside database table ,how if SQL calls the relationship fields between related entity bean.
    did container handle this task.
    example: I have 2 entity bean with CMP(Container Managed Persistence)version 2.0
    call Player and Team. every entity bean have own relationship fields and persistence fields.
    player has playerId(primary key),name,position,age persistence fields and teams is relationship fields.
    team has teamId(primary key),name,city and players is relationship fields.
    I know that all persistence fields is declare in own database table but how about relationship fields.
    can you tellme, How SQL calls can access relationship fields if relatiosnship fields is not declare in database table.
    I use J2EE RI SDK version 1.3
    and deploytool .
    thank's .

    thank's for your reply .Now I have another problem
    I use J2EE RI from java.sun .I try to follow example in j2eetutorial about CMP Example call RosterApp.ear .
    I dont'change anything code inside RosterApp.ear but when I deploy and runclient command thereis syntax error :
    java.rmi.ServerException: Remote exception occured in server thread :nested exception is java.rmi.ServerException :exception thrown from bean :nested exception is : java.ejb.EJBException :nested exception is :java.sql.SQLException :syntax error or access violation ,message from server: "you have an error in SQL syntax near "
    "leagueBeanTable" WHERE "leagueId" = 'L1' at line 1
    in example ,RosterApp.ear use Cloudscape database ,but I try to use Mysql database for RosterApp.ear ,is there any different syntax SQL from Cloudscape to Mysql .
    if like that ,so I must edit first SQL calls from Cloudscape to MYSQL . I think because relationship fields is for entity beans only ,so how if mysql database want to access foreign key another table because foreign key isn't declare in databse table.
    example : I have 3 entity bean call player, team, league .
    1. PlayerEJB have persistence fields name, position, playerId(primary key), cmr fields is teams
    2. TeamEJB have persistence fields name, city, teamId (primary key) , cmr fields is players and leagues .
    3. LeagueEJB have persistence fields name ,sport, leagueId(primary key), cmr fields is teams
    so table is
    PlayerEJB <--->TeamEJB<--->LeagueEJB
    Player have some finder method call findBySport(String Sport) .
    because Sport is persistence fields for LeagueEJB
    so PlayerEJB must traverse TeamEJB first before LeagueEJB
    EJB QL : SELECT distinct object(p) FROM Player (p) IN (p.teams) AS t
    WHERE t.league.sport = ?1
    I know that Container will translates EJB QL to SQL calls ,but default is only for cloudscape database and I use for MYsql .
    so can you helpme how to query method findBySport(String sport) to Mysql calls .
    thereis no foreign key between table in database table there is only Relationship fields in entity bean.

  • Container-managed persistence Entity bean

    WE use a container-managed persistence Entity bean. To handle the state synchronization between the object & the database, what must WE do?
    Thanks in Advance

    That's the container's job. You can use the commit option A/B/C to control how the DB and objects are synchronized.
    -Scott
    http://www.swiftradius.com

  • EJB 3.0 question - saving an entity bean containing another entity bean

    Hi,
    First, I want to store an entity bean. Secondly, I want to store another entity bean - containing the first entity bean.
    I have the following code in a session bean for this:
    public void saveFeedScheduling(FeedScheduling feedScheduling, FeedSource feedSource) {
    FeedSource feeds = em.merge(feedSource);
    em.flush();
    feedScheduling.setFeedSource(feeds);
    FeedScheduling feedSched = em.merge(feedScheduling);
    em.flush();
    This seems to work fine - still, is this the proper way to do it?

    Hello,
    This kind of parameter can be specified using the relationship annotation.
    I'm not 100% sure, but, lok at the "cascade element".
    Regards,
    Sebastien Degardin

  • Connecting to sqlserver from beanManaged entity bean...help me..

    hi all
    I want to connect to SQLServer7.0 from my beanManaged persistence Entity bean.Can any body tell me how to get Connection to data base using JDBC.wether I have to install any new drivers.can i use jdbcodbcbridge drivers.How should my deployment descriptor be?
    If possible give me a simple code snippet.
    Thank you
    srinivas

    hi,
    First:
    Copy %JAVA_HOME%\jre\lib\rt.jar to
    your web server lib folder(Example:J2ee\lib\system\)
    Second:
    make a bean---example:
    package my;
    import java.sql.*;
    public class myDBBean{
    private String DBLocation= "jdbc:odbc:yourDSN";
    private String DBDriver = "sun.jdbc.odbc.JdbcOdbcDriver";
    private ResultSet rs = null;
    private Connection conn = null;
    public myDBBean(){
    public ResultSet executeQuery(String sql){
    if(conn==null){
    DBConnect();
    if(conn==null)
    rs=null;
    else{
    try{
    Statement s=conn.createStatement();
    rs=s.executeQuery(sql);
    catch (SQLException e){
    return(rs);
    public String DBConnect(){
    String strExc="";
    try{
    Class.forName(DBDriver);
    conn=DriverManager.getConnection(DBLocation,"userName","password");
    catch(ClassNotFoundException e){
    strExc=e.toString();
    catch(SQLException e){
    strExc=e.toString();
    return(strExc);
    public void setDBDriver(String driver){
    DBDriver=driver;
    public void setconn(Connection conn){
    conn=conn;
    public String getDBLocation(){
    return(DBLocation);
    public String getDBDriver(){
    return(DBDriver);
    public ResultSet getRs(){
    return(rs);
    public Connection getconn(){
    return(conn);
    Third:
    Compile class file to folder of server classes
    example:j2ee\lib\classes\my\
    Fourth:
    Use jsp file to use the bean
    example:
    <%@ page contentType="text/html;charset=gb2312" %>
    <%@ page import="java.sql.*" %>
    <jsp:useBean id="myDB" class="my.myDBBean" scope="page" />
    <html>
    <head>
    <title>test Sql</title>
    <meta http-equiv="Content-Type" content="text/html;charset=gb2312">
    </head>
    <body>
    <p>Result:</p>
    <%
    String sql;
    ResultSet rs;
    sql="select * from yourTable";
    myDB.DBConnect();
    rs=myDB.executeQuery(sql);
    while(rs.next()){
    out.print("<p>");
    out.print(rs.getString("UserName"));
    out.print("</p>");
    %>
    </body>
    </html>
    hope can help you out.
    David

  • CMP Entity Beans read database row twice?

    Here are two basic questions regarding container managed persistence Entity Beans:
    How many database read operations are performed when a remote reference to a CMP Entity Bean is obtained by a client?
    Is it correct, that each row is read twice?
    For example if a have one row in a database which I want to lookup, AFAIK first the findByPrimaryKey method perfoms a select to lookup the primary key, and then the (container-)ejbLoad method actually reads the row a second time to populate the CMP fields of the bean.
    And how often are UPDATE statements performed?
    Is a database UPDATE statement performed each time a setXX method is invoked?
    Thanks for any help,
    Robert

    How many database read operations are performed when a
    remote reference to a CMP Entity Bean is obtained by a
    client?
    Is it correct, that each row is read twice?It all depends on the CMP system. A simple system might well hit the database twice, once to validate the primary key and once to load the object's fields. A
    smarter system might try to cache the results from the first, so it didn't need to do the second (although this might be a bit dodgy from a transactional point of view).
    However, a couple of facts about databases come in here. Firstly, the query to check the primary key doesn't actually need to load any data from the table: it just needs to check that the key exists. Thus, it should be possible to handle this query just using the index, not touching the table itself at all. Secondly, databases do their own caching, so if a row was loaded in the first query, there is a good chance that it would still be around for the second.
    And how often are UPDATE statements performed?
    Is a database UPDATE statement performed each time a
    setXX method is invoked?Under CMP 1.1, UPDATES are typically done at the end of a transaction; if you use container-demarcated transactions, then yes, UPDATES will happen after every call. If the client code sets up its own transaction, then the UPDATE will only happen after several setXXX calls.
    This can be a performance problem. A common solution is the use of coarse-grained detail objects:
    http://java.sun.com/j2ee/blueprints/sample_application/model/ (section 10.4.1.2)

  • Type of Serialized Object for Entity Bean

    Hi,
    I develop a container managed persistence entity bean. I want to persist an object that is serializable into a database column. My database column type is a Blob. I wonder what is the type of a field in my entity bean? Please help. Thanks in advance.
    Cheers,
    Paul Ngo

    Providing you are not worried about referential integrity, CMP will do this automatically.

  • Error deploying entity bean on web logic server

    i am trying to deploy a container managed persistence entity bean on web logic server when i run the command ejbc which generates the final jar file ready to deploy having its stub and skeleton it gives me the error that the return type of create(int) method should have a type of bean home interface while in accordance with ejb1.1 specicication it should be the type of primary key and a null value should be returned.
    plz let me know where i am doing it wrong.

    thanks for ur quick response sir i am using this services provided by sun microsystem first time and
    am really thankful to Sun Microsystem for this great deal of help to the new commers but sir my problem is still there.
    following is the method which i have written in the code
         public InvoicePK ejbCreate(int id)
              this.id=id;
              return null;
    and here it is the error generated by the server deployment tool.
    [9.2.8] In EJB Invoice, the return type for the create method create(int) must be the bean's remote interface type.
    [9.2.8] In EJB Invoice, the findByPrimaryKey method must return the Entity bean's remote interface type.
    [9.2.8] In EJB Invoice, the return type for the method findByPrimaryKey(com.swi.InvoicePK) must be the entity bean's remote interface type (for a single-object finder) or a collection thereof (for a mult-object finder).
    the detail of files created by me are as follows.
    1. Invoice (Entity Bean)
    2. InvoicePK (Primary Key file)
    3. MyRemoteInterface (remote interface for entity bean)
    4. MyHomeInterface (home interface for entity bean)
    plz let me know where i am doing wrong and oblige.

  • Using JDO under BMP entity beans

    I have an entity bean that is a BMP which uses JDO under the hood. The Oc4J document says that "Bean-managed persistence entity beans manage the resource locking within the bean implementation themselves" in the advanced subject chapter. Ok can someone in oracle add an extra line eloborating on that statement ?
    I am stuck in trying to pass a test that can do concurrent modify of an entity bean. I had 2 or more threads trying to modify one single BMP entity bean object concurrently. The database vendor recognizes one bean had the lock and deny locks to any other beans. Who should block the call to the database until one thread releases the lock on the object ? The developer ? J2EE container ? Database ?
    J2EE tenet "Developers are shielded from concurrency and threading issues while implementing business logic" Does that still hold ??
    An object Person's salary value and his benefit information are tried to be modified at the same time by different external system(salary administrator, benefit's administrator). But I dont want the user to see the lock on the object error, but instead I require a pessimistic lock on the BMP. Why does Oc4J not support pessimistic concurrency option for BMP ?

    Kurien,
    If you wish to bring something to the attention of the "Oracle dev team", I suggest you try Oracle's "MetaLink" Web site:
    http://metalink.oracle.com
    It is the official Oracle support Web site.
    These forums are for the Oracle community. Oracle Corporation employees are not obliged to even visit these forums.
    By the way, I am not an Oracle employee.
    Good Luck,
    Avi.
    P.S. For your information, you may find Debu Panda's blogs of help:
    http://radio.weblogs.com/0135826/

  • Noob Question: Problem with Persistence in First Entity Bean

    Hey folks,
    I have started with EJB3 just recently. After reading several books on the topic I finally started programming myself. I wanted to develop a little application for getting a feeling of the technology. So what I did is to create a AppClient, which calls a Stateless Session Bean. This Stateless Bean then adds an Entity to the Database. For doing this I use Netbeans 6.5 and the integrated glassfish. The problem I am facing is, that the mapping somehow doesnt work, but I have no clue why it doesn't work. I just get an EJBException.
    I would be very thankfull if you guys could help me out of this. And don't forget this is my first ejb project - i might need a very detailed answer ... I know - noobs can be a real ....
    So here is the code of the application. I have a few methods to do some extra work there, you can ignore them, there are of no use at the moment. All that is really implemented is testConnection() and testAddCompany(). The testconnection() Methode works pretty fine, but when it comes to the testAddCompany I get into problems.
    Edit:As I found out just now, there is the possibility of Netbeans to add a Facade pattern to an Entity bean. If I use this, everythings fine and it works out to be perfect, however I am still curious, why the approach without the given classes by netbeans it doesn't work.
    public class Main {
        private EntryRemote entryPoint = null;
        public static void main(String[] args) throws NamingException {
            Main main = new Main();
            main.runApplication();
        private void runApplication()throws NamingException{
            this.getContext();
            this.testConnection();
            this.testAddCompany();
            this.testAddShipmentAddress(1);
            this.testAddBillingAddress(1);
            this.testAddEmployee(1);
            this.addBankAccount(1);
        private void getContext() throws NamingException{
            InitialContext ctx = new InitialContext();
            this.entryPoint = (EntryRemote) ctx.lookup("Entry#ejb.EntryRemote");
        private void testConnection()
            System.err.println("Can Bean Entry be reached: " + entryPoint.isAlive());
        private void testAddCompany(){
            Company company = new Company();
            company.setName("JavaFreaks");
            entryPoint.addCompany(company);
            System.err.println("JavaFreaks has been placed in the db");
        }Here is the Stateless Session Bean. I added the PersistenceContext, and its also mapped in the persistence.xml file, however here the trouble starts.
    import javax.ejb.Stateless;
    import javax.persistence.EntityManager;
    import javax.persistence.PersistenceContext;
    @Stateless(mappedName="Entry")
    public class EntryBean implements EntryRemote {
        @PersistenceContext(unitName="PersistenceUnit") private EntityManager manager;
        public boolean isAlive() {
            return true;
        public boolean addCompany(Company company) {
            manager.persist(company);
            return true;
        public boolean addShipmentAddress(long companyId) {
            return false;
        public boolean addBillingAddress(long companyId) {
            return false;
        public boolean addEmployee(long companyId) {
            return false;
        public boolean addBankAccount(long companyId) {
            return false;
    }That you guys and gals will have a complete overview of whats really going on, here is the Entity as well.
    package ejb;
    import java.io.Serializable;
    import javax.persistence.*;
    @Entity
    @Table(name="COMPANY")
    public class Company implements Serializable {
        private static final long serialVersionUID = 1L;
        @Id
        @GeneratedValue(strategy = GenerationType.AUTO)
        private Long id;
        @Column(name="COMPANY_NAME")
        private String name;
        public Long getId() {
            return id;
        public void setId(Long id) {
            this.id = id;
       public String getName() {
            return name;
        public void setName(String name) {
            this.name = name;
            System.err.println("SUCCESS:  CompanyName SET");
        @Override
        public int hashCode() {
            int hash = 0;
            hash += (id != null ? id.hashCode() : 0);
            return hash;
        @Override
        public boolean equals(Object object) {
            // TODO: Warning - this method won't work in the case the id fields are not set
            if (!(object instanceof Company)) {
                return false;
            Company other = (Company) object;
            if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {
                return false;
            return true;
        @Override
        public String toString() {
            return "ejb.Company[id=" + id + "]";
    }And the persistence.xml file
    <?xml version="1.0" encoding="UTF-8"?>
    <persistence version="1.0" xmlns="http://java.sun.com/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd">
      <persistence-unit name="PersistenceUnit" transaction-type="JTA">
        <provider>oracle.toplink.essentials.PersistenceProvider</provider>
        <jta-data-source>jdbc/sample</jta-data-source>
        <exclude-unlisted-classes>false</exclude-unlisted-classes>
        <properties>
          <property name="toplink.ddl-generation" value="create-tables"/>
        </properties>
      </persistence-unit>
    </persistence>And this is the error message
    08.06.2009 10:30:46 com.sun.enterprise.appclient.MainWithModuleSupport <init>
    WARNUNG: ACC003: Ausnahmefehler bei Anwendung.
    javax.ejb.EJBException: nested exception is: java.rmi.ServerException: RemoteException occurred in server thread; nested exception is:
            java.rmi.RemoteException: Transaction aborted; nested exception is: javax.transaction.RollbackException: Transaktion für Zurücksetzung markiert.; nested exception is:
            javax.transaction.RollbackException: Transaktion für Zurücksetzung markiert.
    java.rmi.ServerException: RemoteException occurred in server thread; nested exception is:
            java.rmi.RemoteException: Transaction aborted; nested exception is: javax.transaction.RollbackException: Transaktion für Zurücksetzung markiert.; nested exception is:
            javax.transaction.RollbackException: Transaktion für Zurücksetzung markiert.
            at com.sun.corba.ee.impl.javax.rmi.CORBA.Util.mapSystemException(Util.java:243)
            at com.sun.corba.ee.impl.presentation.rmi.StubInvocationHandlerImpl.privateInvoke(StubInvocationHandlerImpl.java:205)
            at com.sun.corba.ee.impl.presentation.rmi.StubInvocationHandlerImpl.invoke(StubInvocationHandlerImpl.java:152)
            at com.sun.corba.ee.impl.presentation.rmi.bcel.BCELStubBase.invoke(BCELStubBase.java:225)
            at ejb.__EntryRemote_Remote_DynamicStub.addCompany(ejb/__EntryRemote_Remote_DynamicStub.java)I spend half the night figuring out whats wrong, however I couldnt find any solution.
    If you have any idea pls let me know
    Best regards and happy coding
    Taggert
    Edited by: Taggert_77 on Jun 8, 2009 2:27 PM

    Well I don't understand this. If Netbeans created a Stateless Session Bean as a facade then it works -and it is implemented as a CMP, not as a BMP as you suggested.
    I defenitely will try you suggestion, just for curiosity and to learn the technology, however I dont have see why BMP will work and CMP won't.
    I also don't see why a stateless bean can not be a CMP. As far as I read it should not matter. Also on the link you sent me, I can't see anything related to that.
    Maybe you can help me answering these questions.
    I hope the above lines don't sound harsh. I really appreciate your input.
    Best regards
    Taggert

  • [persistence] all work, but can't persist new entity bean

    Hi,
    I have a FacadeBean which is working fine ... I can contact the BD oracle for retrieving my entity beans, update an entity bean etc...
    BUT... I can't create an entity bean :( I don't understand why!!!
    With the same code, I can create, list, etc... on OC4J and JBoss but the create method won't work with WebLogic :|
    Here is the error present in console:
    <09-mars-2007 15 h 03 min 47 s CET> <Error> <EJB> <BEA-010026> <Exception occurr
    ed during commit of transaction Name=[EJB be.starapic.test.ejb.MyEntityFacadeBea
    n.create(be.starapic.test.ejb.MyEntity)],Xid=BEA1-007A82AF3A953057A4BD(30283302)
    ,Status=Rolled back. [Reason=weblogic.transaction.internal.AppSetRollbackOnlyExc
    eption],numRepliesOwedMe=0,numRepliesOwedOthers=0,seconds since begin=1,seconds
    left=30,XAServerResourceInfo[weblogic.jdbc.wrapper.JTSXAResourceImpl]=(ServerRes
    ourceInfo[weblogic.jdbc.wrapper.JTSXAResourceImpl]=(state=rolledback,assigned=Ad
    minServer),xar=weblogic.jdbc.wrapper.JTSXAResourceImpl@110563c,re-Registered = f
    alse),SCInfo[base_domain+AdminServer]=(state=rolledback),properties=({weblogic.t
    ransaction.name=[EJB be.starapic.test.ejb.MyEntityFacadeBean.create(be.starapic.
    test.ejb.MyEntity)], weblogic.jdbc=t3://192.168.100.188:7001}),OwnerTransactionM
    anager=ServerTM[ServerCoordinatorDescriptor=(CoordinatorURL=AdminServer+192.168.
    100.188:7001+base_domain+t3+, XAResources={weblogic.jdbc.wrapper.JTSXAResourceIm
    pl},NonXAResources={})],CoordinatorURL=AdminServer+192.168.100.188:7001+base_dom
    ain+t3+): weblogic.transaction.RollbackException: Unknown reason
    at weblogic.transaction.internal.TransactionImpl.throwRollbackException(
    TransactionImpl.java:1808)
    at weblogic.transaction.internal.ServerTransactionImpl.internalCommit(Se
    rverTransactionImpl.java:333)
    at weblogic.transaction.internal.ServerTransactionImpl.commit(ServerTran
    sactionImpl.java:227)
    at weblogic.ejb.container.internal.BaseRemoteObject.postInvoke1(BaseRemo
    teObject.java:606)
    at weblogic.ejb.container.internal.BaseRemoteObject.postInvokeTxRetry(Ba
    seRemoteObject.java:426)
    at weblogic.ejb.container.internal.StatefulRemoteObject.postInvokeTxRetr
    y(StatefulRemoteObject.java:100)
    at be.starapic.test.ejb.myentityfacade_opn58i_MyEntityFacadeRemoteImpl.c
    reate(myentityfacade_opn58i_MyEntityFacadeRemoteImpl.java:158)
    at be.starapic.test.ejb.myentityfacade_opn58i_MyEntityFacadeRemoteImpl_C
    BV.create(Unknown Source)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
    java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
    sorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:585)
    at weblogic.ejb.container.internal.RemoteBusinessIntfProxy.invoke(Remote
    BusinessIntfProxy.java:42)
    at $Proxy152.create(Unknown Source)
    at be.starapic.test.web.HelloServlet.doGet(HelloServlet.java:88)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
    at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run
    (StubSecurityHelper.java:226)
    at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecuri
    tyHelper.java:124)
    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.jav
    a:283)
    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.jav
    a:175)
    at weblogic.servlet.internal.WebAppServletContext$ServletInvocationActio
    n.run(WebAppServletContext.java:3334)
    at weblogic.security.acl.internal.AuthenticatedSubject.doAs(Authenticate
    dSubject.java:321)
    at weblogic.security.service.SecurityManager.runAs(Unknown Source)
    at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppS
    ervletContext.java:2081)
    at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletC
    ontext.java:1987)
    at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.j
    ava:1359)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:200)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:172)
    .>
    <09-mars-2007 15 h 03 min 47 s CET> <Error> <HTTP> <BEA-101020> <[weblogic.servl
    et.internal.WebAppServletContext@144a314 - appName: 'testDeploy', name: '/testDe
    ploy', context-path: '/testDeploy'] Servlet failed with Exception
    javax.ejb.EJBException: nested exception is: weblogic.transaction.internal.AppSe
    tRollbackOnlyException
    at weblogic.ejb.container.internal.RemoteBusinessIntfProxy.invoke(Remote
    BusinessIntfProxy.java:57)
    at $Proxy152.create(Unknown Source)
    at be.starapic.test.web.HelloServlet.doGet(HelloServlet.java:88)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
    Truncated. see log file for complete stacktrace
    That say nothing good...
    at $Proxy152.create(Unknown Source) is the problem I think but why ...?
    Here is the entity bean:
    @Entity
    @Table(name="table_myentity")
    public class MyEntity implements Serializable
    private static final long serialVersionUID = -5806278646729410835L;
    private int id;
    private String name;
    private int number;
    public void setName(String name) {
    this.name = name;
    public String getName() {
    return name;
    public void setNumber(int number) {
    this.number = number;
    @Column(name="mynumber")
    public int getNumber() {
    return number;
    public void setId(int id) {
    this.id = id;
    @Id
    @GeneratedValue(strategy=GenerationType.AUTO)
    public int getId() {
    return id;
    May be a problem of auto-generate for the ID...
    Here is the facade bean:
    @Stateful(name="myentityfacade", mappedName="myentityfacade")
    @Remote(MyEntityFacadeRemote.class)
    @Local(MyEntityFacadeLocal.class)
    public class MyEntityFacadeBean implements MyEntityFacadeRemote, MyEntityFacadeLocal {
    @PersistenceContext
    private EntityManager em;
    public MyEntity create(MyEntity meb) {
    em.persist(meb);
    return meb;
    public void update(MyEntity meb) throws IllegalAccessException {
    if (null == em.find(MyEntity.class, meb.getId())) {
    throw new IllegalAccessException("Attempt to update a non existing entity");
    em.merge(meb);
    public void delete(int id) {
    MyEntity meb = em.find(MyEntity.class, id);
    em.remove(meb);
    public void delete(MyEntity meb) {
    meb = em.merge(meb);
    em.remove(meb);
    public MyEntity findById(int id) {
    return em.find(MyEntity.class, id);
    public List<MyEntity> listAll() {
    return em.createQuery("SELECT o FROM MyEntity AS o").getResultList(); //TOPLINK, HIBERNATE
    public List<MyEntity> listFiltered(String filter) {
    return em.createQuery("SELECT o FROM MyEntity AS o "+filter).getResultList(); //TOPLINK, HIBERNATE
    public int getNbMyEntityBean() {
    return this.listAll().size();
    Sorry for the long post... And finnaly here is the code present in the servlet:
    // CREATE
    MyEntity meb1 = new MyEntity();
    meb1.setName("bbb");
    meb1.setNumber(2);
    meb1 = remoteMyEntityFacade.create(meb1);
    Note that the remoteMyEntityFacade is working, because I can call any other buisness method without crashing the application.. Just the create can't work and so, persistence can't be used :(
    Any suggestions ?

    There is a problem with generated key
    that code won't work:
    @Id
    @GeneratedValue(strategy=GenerationType.AUTO)
    public int getId() {
    return id;
    But, if I remove line "GeneratedValue", it can insert into the BD, once only :s
    The ID is set to 0 by default, so I can't add more than one entity :s

  • How to specify JDBC Oracle url using deployment tool - Entity Bean

    Hello I'am new to EJB.
    When creating a entity bean-managed persistence and you need to specify the jdbc url with user name
    and password to establish a connection object, how does one specify that in the deployment
    tool?
    Heres an example of what has in the J2EE tutorial has in AccountEJB to get an connection object
    private String dbName = "java:comp/env/jdbc/AccountDB";
    private void makeConnection() throws NamingException, SQLException {
    InitialContext ic = new InitialContext();
    DataSource ds = (DataSource) ic.lookup(dbName);
    con = ds.getConnection();
    Now if my oracle jdbc url is to be jdbc:oracle:thin:@Abe:1521:dev
    ie My host is Abe, port number 1521 and database name of dev and username/password will be system/manager.
    what would my dbName be at the top?
    Would my JNDI lookup of a DataSource resource "java:comp/env/jdbc/AccountDB" become "java:comp/env/jdbc/dev" for starters?
    In the Resource Factories Reference Code I've add a reference of
    Coded Name: jdbc/dev
    Type: javax.sql.DataSource
    Authentication: Container
    and down the bottom of the I've put JNDI Name: MyAccount
    according to the AccountClient code of:
    Context initial = new InitialContext();
    Object objref = initial.lookup("MyAccount");
    and put User Name of "system" and Password of "manager"
    I'am sure in the source code I have to put
    Class.forName("oracle.jdbc.driver.OracleDriver")
    else you would get that no sutitable driver error, maybe you don't have to if ejb server is smart enough?
    What I'am confuse about is where to specify the jdbc url of "jdbc:oracle:thin:@Abe:1521:dev" ??
    Know it won't work because of this vital part. Do you have to put that somewhere else in the deployment tool or properties file, or some other tool??
    Please help
    Thanks
    Abraham Khalil

    When running the client after successful deployment with jdbc, I'am getting
    javax.naming.CommunicationException: java.rmi.MarshalException: CORBA MARSHAL 1398079699 Maybe; nested exception is:
    org.omg.CORBA.MARSHAL: Unable to read value from underlying bridge : minor code: 1398079699 completed: Maybe
    org.omg.CORBA.MARSHAL: Unable to read value from underlying bridge : minor code: 1398079699 completed: Maybe
    at com.sun.corba.ee.internal.iiop.CDRInputStream_1_0.read_value(CDRInputStream_1_0.java:923)
    at com.sun.corba.ee.internal.iiop.CDRInputStream.read_value(CDRInputStream.java:281)
    at com.sun.corba.ee.internal.corba.TCUtility.unmarshalIn(TCUtility.java:274)
    at com.sun.corba.ee.internal.corba.AnyImpl.read_value(AnyImpl.java:554)
    at com.sun.corba.ee.internal.iiop.CDRInputStream_1_0.read_any(CDRInputStream_1_0.java:605)
    at com.sun.corba.ee.internal.iiop.CDRInputStream.read_any(CDRInputStream.java:252)
    at com.sun.corba.ee.internal.javax.rmi.CORBA.Util.readAny(Util.java:203)
    at javax.rmi.CORBA.Util.readAny(Unknown Source)
    at org.omg.stub.com.sun.enterprise.naming._SerialContextProvider_Stub.lookup(Unknown Source)
    at com.sun.enterprise.naming.SerialContext.lookup(SerialContext.java:133)
    at javax.naming.InitialContext.lookup(Unknown Source)
    at AccountClient.main(AccountClient.java:21)
    at com.sun.enterprise.naming.SerialContext.lookup(SerialContext.java:151)
    at javax.naming.InitialContext.lookup(Unknown Source)
    at AccountClient.main(AccountClient.java:21)
    One thing I don't like about EJB is that everything is transparent which is good! But its much
    harder to debug! :( Tried to see if I can figure it out. Hope someone has seen this problem before?

  • EJB Entity beans ,JDBC Stored procedures

    Hi ,
    I am new to EJB and i have some general questions
    ---Every table in an existing database is an entity bean for my application?
    --- how do i define the queries in the entity bean ? (With PreparedStatement ?)
    ---The persistent fields,the ejbmethods,constructors, the table relationships, the prepared statements and stored procedures, are defined in the entity beans ?
    --- how do i define the primary Keys in an Entity Bean !!! I will use EJB 2.1 and BMP
    thanks in advance ...

    Sandeep...
    I have dblinks going all over the place. What you are talking about is a clustered or distributed database. That is the future (or present ) of large databases. My code is set up because an 'architecture' is not yet available in the database itself to support the concepts I've posted to Steve in other threads.
    I fully believe that we'll eventually have BC4J ( or something like it ) directly in the database. I fully believe that the database will load balance these across a cluster of databases, within the database structure itself. For example... there is NOTHING to stop the JVM from deciding that it needs to load balance and submit the thread to a remote machine for processing... independent of creating a "middle tier" outside the database.
    I believed that client-server model was flawed for most (not all) applications in the 80's. Looking at the "application tier" model I have the same feeling that we're creating an overly complex scheme at the wrong layer... just pushed back one stage so that we have to rewrite everything...
    If you go back to the megalithic server design ( or cluster of servers ) with a thin thin front end... just why is the middle tier needed under the scenario I've outlined?
    As such, stored procedures/triggers be they in java or pl/sql seems best bet to me... seeing's how a call spec to java or a pl/sql wrapper is transparent to the caller using jdbc or any other future technology.
    grin Way outside the scope of the universe today... I see it as inevitable.
    null

  • JDBC or Entity Beans for Read-Only Data?

    Entity beans are way to slow on pulling the amount of data I need. What are the cons of just using JDBC? Is this bad programming?
    One query pulls about 700 rows from 6 different tables taking up to 20 seconds. The same call using JDBC takes 2 seconds. What is the proper thing to do?

    One query pulls about 700 rows from 6 different
    tables taking up to 20 seconds. The same call using
    JDBC takes 2 seconds. What is the proper thing to do?JDBC. Entity beans are not really suited for data across multiple tables. This can be best done with plain SQL +JDBC.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • JDBC issue when accessing an Entity Bean

    Hi,
    WLCS 3.1
    WLS 5.1 sp6
    Windows NT
    Oracle 8.1.6
    I am having problems with an Entity bean, I have originaly deployed and had it
    running on cloudscape. I decided I need to deploy it to Oracle 8.1.6, on startup
    of WLCS the bean was deployed to the connection pool correctly using Weblogic
    JDriver.
    The bit I cannot understand is when I try and do a FindByPrimaryKey on the Entity
    Bean the following exception is thrown by oracle, which leads me to believe this
    must be an Oracle/Jdbc problem.
    Here you can see that the bean has been deployed on a valid connection pool.
    Tue Sep 18 15:47:39 GMT+03:00 2001:<I> <EJB JAR deployment /export/home/mccann/tester2.jar>
    EJB home interface: 'com.testerHome' deployed bound to the JNDI name
    : 'tester'
    Heres the exception raised when a findByPrimaryKey is invoked on the bean....
    Tue Sep 18 15:47:57 GMT+03:00 2001:<I> <EJB JAR deployment /export/home/mccann/t
    ester2.jar> Exception in non-transactional EJB invoke:
    java.sql.SQLException: ORA-00942: table or view does not exist
    at weblogic.db.oci.OciCursor.getCDAException(OciCursor.java:228)
    at weblogic.jdbcbase.oci.Statement.executeUpdate(Statement.java:869)
    at weblogic.jdbc.pool.PreparedStatement.executeUpdate(PreparedStatement.
    java:65)
    at com.testerEJBPSWebLogic_CMP_RDBMS.create(testerEJBPSWebLogic_CMP_RDBM
    S.java:199)
    at com.testerEJBPSWebLogic_CMP_RDBMS.create(testerEJBPSWebLogic_CMP_RDBM
    S.java:162)
    at weblogic.ejb.internal.EntityEJBContext.create(EntityEJBContext.java:1
    18)
    at weblogic.ejb.internal.StatefulEJBObject.postCreate(StatefulEJBObject.
    java:268)
    at com.testerEJBEOImpl.create(testerEJBEOImpl.java:61)
    at com.testerEJBHomeImpl.create(testerEJBHomeImpl.java:32)
    at com.testerEJBHomeImpl_WLSkel.invoke(testerEJBHomeImpl_WLSkel.java:68)
    at weblogic.rmi.extensions.BasicServerObjectAdapter.invoke(BasicServerOb
    jectAdapter.java:347)
    at weblogic.rmi.extensions.BasicRequestHandler.handleRequest(BasicReques
    tHandler.java:69)
    at weblogic.rmi.internal.BasicExecuteRequest.execute(BasicExecuteRequest
    .java:15)
    at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:135)
    Any help here would be great, this is annoying problem because the Entity bean
    deploys fine and no issues are raised at startup time, so the table must of existed
    and the structure must of been correct. But minutes after the server started I
    ran my client which tried to invoke this bean with the above exception.
    Thanks
    Wayne.

    Hi Wayne,
    I'd recommend you installing of latest SP for WL plus installing of Oracle
    8.1.7 thing driver.
    Regards,
    Slava Imeshev
    "Wayne Highland" <[email protected]> wrote in message
    news:[email protected]...
    >
    Hi,
    WLCS 3.1
    WLS 5.1 sp6
    Windows NT
    Oracle 8.1.6
    I am having problems with an Entity bean, I have originaly deployed andhad it
    running on cloudscape. I decided I need to deploy it to Oracle 8.1.6, onstartup
    of WLCS the bean was deployed to the connection pool correctly usingWeblogic
    JDriver.
    The bit I cannot understand is when I try and do a FindByPrimaryKey on theEntity
    Bean the following exception is thrown by oracle, which leads me tobelieve this
    must be an Oracle/Jdbc problem.
    Here you can see that the bean has been deployed on a valid connectionpool.
    >
    Tue Sep 18 15:47:39 GMT+03:00 2001:<I> <EJB JAR deployment/export/home/mccann/tester2.jar>
    EJB home interface: 'com.testerHome' deployed bound to the JNDI name
    : 'tester'
    Heres the exception raised when a findByPrimaryKey is invoked on thebean....
    >
    Tue Sep 18 15:47:57 GMT+03:00 2001:<I> <EJB JAR deployment/export/home/mccann/t
    ester2.jar> Exception in non-transactional EJB invoke:
    java.sql.SQLException: ORA-00942: table or view does not exist
    at weblogic.db.oci.OciCursor.getCDAException(OciCursor.java:228)
    atweblogic.jdbcbase.oci.Statement.executeUpdate(Statement.java:869)
    atweblogic.jdbc.pool.PreparedStatement.executeUpdate(PreparedStatement.
    java:65)
    atcom.testerEJBPSWebLogic_CMP_RDBMS.create(testerEJBPSWebLogic_CMP_RDBM
    S.java:199)
    atcom.testerEJBPSWebLogic_CMP_RDBMS.create(testerEJBPSWebLogic_CMP_RDBM
    S.java:162)
    atweblogic.ejb.internal.EntityEJBContext.create(EntityEJBContext.java:1
    18)
    atweblogic.ejb.internal.StatefulEJBObject.postCreate(StatefulEJBObject.
    java:268)
    at com.testerEJBEOImpl.create(testerEJBEOImpl.java:61)
    at com.testerEJBHomeImpl.create(testerEJBHomeImpl.java:32)
    atcom.testerEJBHomeImpl_WLSkel.invoke(testerEJBHomeImpl_WLSkel.java:68)
    atweblogic.rmi.extensions.BasicServerObjectAdapter.invoke(BasicServerOb
    jectAdapter.java:347)
    atweblogic.rmi.extensions.BasicRequestHandler.handleRequest(BasicReques
    tHandler.java:69)
    atweblogic.rmi.internal.BasicExecuteRequest.execute(BasicExecuteRequest
    java:15)
    at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:135)
    Any help here would be great, this is annoying problem because the Entitybean
    deploys fine and no issues are raised at startup time, so the table mustof existed
    and the structure must of been correct. But minutes after the serverstarted I
    ran my client which tried to invoke this bean with the above exception.
    Thanks
    Wayne.

Maybe you are looking for

  • Can't Get Edits to "Stick" in ACR

    I've been using Bridge to correct my Raw files for about 8 years. In the last month, I'm finding that there are times that the edits I do in Adobe Camera Raw just don't "stick" - I'll edit the file in the ACR window, and click "Done" and expect to se

  • Is it possible to reset the default image size for VIEW in photoshop elements EDIT menu?

    When I go into the Edit menu, I have to click on "Fit on Screen" to enlarge the view.  Is there a way to change the default size of the  Edit image so that the larger size I get with "Fit on Screen" is the new default?"

  • I want to create a traffic light sequence in labview

    Hi, I'm very new to Labview(first post here) and am learning by trying some simple things. I'm trying to create a continuous running traffic light system, RED, THEN RED AND AMBER, THEN JUST GREEN, THEN JUST AMBER, THEN JUST RED, and repeat the sequen

  • Image as drop target for drag and drop

    was wondering how I can make an image to be a drop target using the dnd api. so far from what i've seen it takes only java components to be target, so if anyone has any ideas it will be great. thanks

  • Script to load documents in KM Repository DB mode

    Is there any good documentation on writing a script to load documents into a KM repository that is set up in DB mode?  In the past we had this repository as an FSDB and we could create scripts to upload to the file system.  Now in DB mode we need to