cancel
Showing results for 
Search instead for 
Did you mean: 

how to pass a String as a NUMC in backwnd table

Former Member
0 Kudos

Hi All

I have a Backend Table with the Field name : PERNR, having Type as "NUMC"

From portal I have got the Selcted Pernr in a form of a String. But when I am passing this to table, it gives me below error at runtime :

com.sap.aii.proxy.framework.core.DataAccessException: Type conversion error, field PERNR, complex type class com.abb.model.Zexigo_Pernr

So please tell me how should I pass NUMC value from a String value.

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Convert the String to int with Integer.parseInt(pernr).

Regards

Former Member
0 Kudos

remember that for parsing, you need to catch the numberformat exception:


int numchar = 0;
try{
    numchar = Integer.parseInt(number);
}catch(NumberFormatException e){
    //print a message or something
}

Former Member
0 Kudos

Hi Nikesh,

Sorry for that.

You can refer this link:

/thread/1692735 [original link is broken]

In this case, they hav used a table and trying to pass multiple pernr number.

Regards,

Jithin

Former Member
0 Kudos

Hi Nikesh,

Check this link:

Regards,

Jithin

Former Member
0 Kudos

Hi Jithin,

I am talking about WDJ and not about WDA applications. I didnt understand after reading the thread. It wud be helpful if someone posts Java code for the same.