Wednesday 13 March 2013

Creating EJB (Entity Beans) in WCS

Next 5 slides shows how we can insert a record in database and update it in WCS using EJB.

1)First create a table:

CREATE TABLE DB2ADMIN.XBONUS  (
          MEMBERID BIGINT NOT NULL ,
          BONUSPOINT INTEGER NOT NULL ,
          OPTCOUNTER SMALLINT NOT NULL,
CONSTRAINT XBONUS_PK PRIMARY KEY (MEMBERID),
CONSTRAINT XBONUS_FK FOREIGN KEY (MEMBERID) REFERENCES DB2ADMIN.USERS(USERS_ID));


2)Follow below steps to create Entity Beans 































Click on Finish button-> This creates all the required, Home/Remote/Bean classes

























3)Next we see how to Configure EJB Properties

No comments:

Post a Comment