• Font Size
  • S
  • M
  • L

Search via FAQ No.


  • No : 24464
  • Open Date : 2016/06/13 14:15
  • 更新日時 : 2020/09/16 14:34
  • Print

[DataSpider Servista] Error has occurred when writing the file that has been read in the Fixed Adapter, to the table

The below error has occurred when writing the file that has been read in the Fixed Adapter, to the database table.
 
Null data saving is permitted as number type for the relevant column of the table. The error can be avoided by converting the Null value into 0 after the trim in the logic icon of Mapper. However, it will be an error if the blank space is removed by trim. Explain about the error cause and its handling method.

Unable to convert the type from String to BigDecimal.
 
Category : 

Answer

*Contents linked from this page might be in Japanese.
 
■Causes
 
The error message in Q occurs when you attempt to convert the string to number and fail to do so. For instance, it is not possible to convert empty string to number type. Hence, it will be an error, when empty string is set to numeric fields.
 
When you set the value in the number field of the database or application same as this case, DataSpider Servista will convert the string type data to number internally. Hence, when you try to set the empty string data to the number type field, it would result in an error.
 
In the file reading process of Fixed-Length adapter, the value of the column without data is read as null or empty string based on the settings. Refer to the help in the reference information for the conditions of null or empty string.
 
■Measures to avoid
 
Convert the empty string such as 0 to optional number using the null/empty string conversion logic of Mapper.
 
・Fixed-Length file reading process - For null and empty string