prasanna kumar

Greenhorn
+ Follow
since Jun 27, 2004
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by prasanna kumar

We recently converted our EJB2.1 application to EJB3 (Jboss 4.2.CP07) and landed in to a problem with EntityExistsException Vs DuplicateKeyException (EJB2).
Earlier with EJB2 we were able to do operation like

try{
<EntityHome>.create(<some object>);
} catch (DuplicateKeyException ex) {
Do some other task ..involving database
}

When we converted to EJB3 ..the code looks like below

try{
em.persist(<some PO>);
} catch (EntityExistsException ex) {
Do some other task ..using em

}

In second case we learnt that we couldn't do any more operations on the em as the transaction is closed, is this the expected behavior?
If yes can anyone please suggest a different way to handle these scenarios ?
We recently converted our EJB2.1 application to EJB3 (Jboss 4.2.CP07) and landed in to a problem with EntityExistsException Vs DuplicateKeyException (EJB2).
Earlier with EJB2 we were able to do operation like

try{
<EntityHome>.create(<some object>);
} catch (DuplicateKeyException ex) {
Do some other task ..involving database
}

When we converted to EJB3 ..the code looks like below

try{
em.persist(<some PO>);
} catch (EntityExistsException ex) {
Do some other task ..using em

}

In second case we learnt that we couldn't do any more operations on the em as the transaction is closed, is this the expected behavior?
If yes can anyone please suggest a different way to handle these scenarios ?

Hello Everyone,

i have a situation where I'm passing method name as a string. i need to call this method on a object.

let me make myself clear..

lets say there is a object bankdetails. it has like 100 methods method1(), method2(),...and so on
i have a string object which gets method names like "method1" or "method2" or..
i need to check this string value and call bankdetails.method1 or bankdetails.method2 or... so on based on this string's value.
one way of doing this would be to use multiple if then else statements to see the values and call the appropriate method. in this case if the object has 100 methods then i need to write 100 statements to check for this...
like (if methodname == "method1" then call bankdetails.method1 else if methodname == "method2" then call bankdetails.method2 ..)

i surely feel there should be another way of doing this..

thanks in advance
arun
18 years ago
Hello friends

I'm converting a report which is in jsp file to a Comma separated value format.
whats happenening is when the field is a String which has numeric values like "123456678979708" the csv format treats it as a number and the data is printed in the excel sheet in the scientific notation. like 1.2 E10. IS there anyway to specify it as a plain text so that the number prints as it is.
I tried several approaches
1) I tried inserting a space before the number in the jsp so that the excel will consider it as a plain string
2) I tried putting the data within quotes in the jsp --- did not work either
3) I tried putting a '/' character .. still did not work

Is there any work around for this??
thanks

arun
18 years ago
JSP
hello people,


I want to know what EJB spec is the scea exam part 1 based on.

I'm comfortable with EJB 2.0 and since there r a lot of differences regarding EJB 1.1 and EJB 2.0 I just wanted some clarification.

Thanks a lot in advance

Arun
hello people,


I want to know what EJB spec is the scea exam part 1 based on.

I'm comfortable with EJB 2.0 and since there r a lot of differences regarding EJB 1.1 and EJB 2.0 I just wanted some clarification.

Thanks a lot in advance

Arun
Hello friends,

I did my first chapter on HEAD FIRST ejb and tried to execute the first program AdviceClient.java.
the compilation into respective directories all went fine.
but when i run the AdviceClient.java i get runtime exception
some CORBA error. corba.util.mapexception error

i need suggestions
Arun
Hello people,

I'm a beginner to EJB Technology.
i tried compiling the home,component,bean.java files but the compiler says that package javax.ejb doesn't exist...
the error is on the line javax.ejb.*;
I would really appreciate if anyone can give any suggestions.
Since This is the first step i'm not able to proceed further.

I downloaded the j2ee RI server
and I set the environment varaiables as

J2EE_HOME - c:\j2sdkee1.3.1
JAVA_HOME - c:\j2sdk1.4.2_04
PATH - c:\j2sdkee1.3.1\bin;c:\j2sdk1.4.2_04\bin
do i need to set up the classpath to j2ee.jar? if so
do I find the j2ee.jar file and how do i set up the classpath

I would be grateful if anyone can clear this.



Thank you
Arun
I downloaded the j2ee RI server
and I set the environment varaiables as

J2EE_HOME - c:\j2sdkee1.3.1
JAVA_HOME - c:\j2sdk1.4.2_04
PATH - c:\j2sdkee1.3.1\bin;c:\j2sdk1.4.2_04\bin
do i need to set up the classpath to j2ee.jar? if so
do I find the j2ee.jar file and how do i set up the classpath

I would be grateful if anyone can clear this.

thanks
Arun
Hello people,

I'm a beginner to EJB Technology.
i tried compiling the home,component,bean.java files but the compiler says that package javax.ejb doesn't exist...
the error is on the line javax.ejb.*;
I would really appreciate if anyone can give any suggestions.
Since This is the first step i'm not able to proceed further.

Thank you
Arun
Thanks a lot Nick
Hello people,

I passed the IBM 285 exam. I need to know when I will be receiving my certification from IBM.
Also How do I get the ibm certified professional logo?
i would really appreciate any response

arun