Skip to main content Skip to complementary content
  • New archived content: Talend MDM, Talend Data Catalog 8.0, and Talend 7.3 products reached their end of life in 2024. Their documentation was moved to the Talend Archive page and will no longer receive content updates.
Close announcements banner

isCastable

Returns true if the input value can be converted to a given data type.

Information noteNote: This feature is only available in Talend Cloud Pipeline Designer and Talend Data Mapper.

Arguments

  1. Input value.
  2. String containing the name of a data type. The following values are supported:
    • BigDecimal
    • Decimal or Dec
    • Bytes
    • DateTime
    • Date
    • Time
    • Integer or Int
    • Long
    • Float
    • Double
    • String
    • Boolean or Bool
    • Null

    These values are case-insensitive.

Examples

Expression Result
isCastable("Hello World", "bool") true
isCastable("Hello World", "INTEGER") false

Did this page help you?

If you find any issues with this page or its content – a typo, a missing step, or a technical error – please let us know!