cancel
Showing results for 
Search instead for 
Did you mean: 

Error in receiver JDBC channel

0 Kudos

Hi,

I have a receiver JDBC scenario, which must execute a stored procedure.

Output message seems correct:

<ns0:MT_SQL xmlns:ns0="http://www.xxxx">

<STATEMENT1>

<DIRECC ACTION="EXECUTE">

<TABLE>biz_mag_clientes_direcciones</TABLE>

<idcliente type="VARCHAR">0001000692</idcliente>

<idtipodir type="VARCHAR">1</idtipodir>

<iddireccion type="VARCHAR">0210054466</iddireccion>

<idtipovia type="INTEGER">1</idtipovia>

<idciclovida type="VARCHAR" />

<idmaestro type="VARCHAR" />

<idtiporeplicacion type="VARCHAR" />

<cp type="VARCHAR">08188</cp>

<callenum type="VARCHAR">UR CAN SALA XIC APDO. CORREOS 507,</callenum>

<telefono type="VARCHAR">9999999</telefono>

<observacion type="VARCHAR" />

<grupocnae type="VARCHAR">55</grupocnae>

<subgrupocnae type="VARCHAR">5541</subgrupocnae>

</DIRECC>

</STATEMENT1>

</ns0:MT_SQL>

But there is an error in receiver CC:

Unable to execute statement for table or stored procedure. 'biz_mag_clientes_direcciones' due to java.lang.NumberFormatException: For input string: "1 "

I think this problem it's due to idtipovia field (INTEGER type), but i don't know how to solve it.

Any input, please ? Thanks

Carme.

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi

it may be OK [idtipovia type="VARCHAR" ]

regards

Former Member
0 Kudos

Hi Carme,

idtipovia has space character behind "1"

Regards,

Yuki,Fuji

former_member181962
Active Contributor
0 Kudos

Hi Carme,

Check if the value 1 has preceeding or succeeding spaces.

Regards,

Ravi Kanth Talagana

0 Kudos

No, it has any space.

Copied from payload directly --> <idtipovia type="INTEGER">1</idtipovia>

Regards,

Carme.

former_member181962
Active Contributor
0 Kudos

Hi Carme,

How did you define the type for idtipovia field in the data type?

xsd:integer or xsd:string? I think it should be xsd:integer

Regards,

ravi

0 Kudos

Yuki, if i defined this field as CHAR, cc returned this error:

JDBC message processing failed; reason Error processing request in sax parser: Error when executing statement for table/stored proc. 'biz_mag_clientes_direcciones' 😞 com.microsoft.sqlserver.jdbc.SQLServerException: Error converting data type nvarchar to int.

Because this field is INTEGER type in target stored procedure .

Ravi, This field is defined as xsd:integer in data type.

Thanks,

Carme.