One Star

cannot convert from int to BigDecimal

I am trying to insert some records in oracle table as target and it has one NUMBER type column.
 The field is not null type so I am trying to insert default value 0 from mapping. I have created one variable in tmap with dataype integer and have put 0 in expression. 
I have not set BigDecimal in table or in variable still it is giving error like below
Exception in thread "main" java.lang.Error: Unresolved compilation problem: 
Type mismatch: cannot convert from int to BigDecimal
Please give suggestion to resolve this error.
Thanks.
2 REPLIES
Moderator

Re: cannot convert from int to BigDecimal

Hi,
 The field is not null type so I am trying to insert default value 0 from mapping. I have created one variable in tmap with dataype integer and have put 0 in expression. 
I have not set BigDecimal in table or in variable still it is giving error like below

It seems something wrong with you expression. Could you please post your tMap editor screenshot into forum which will be helpful for us to address your issue?
Best regards
Sabrina
--
Don't forget to give kudos when a reply is helpful and click Accept the solution when you think you're good with it.
One Star

Re: cannot convert from int to BigDecimal

Hi,
 It got resolved. Talend has assumed the datatype as bigdecimal though it was not in datatype. I have update it from metadata and tmap so it is now working fine. 
Thanks.