5 Replies Latest reply on Jul 17, 2019 8:48 AM by rareddy

    Is Teiid provide any API for validating data before actual insertion?

    pranitag

      Hi Team,

       

      There is a facility of implicit and explicit casting in every database. If my target column's datatype mismatch with data I am trying to insert then teiid throws following error on runtime:

      Caused by: org.teiid.core.types.TransformationException: TEIID10076 Invalid conversion from type class org.teiid.core.types.BinaryType with value '303130303131303130' to type class java.lang.String

      Is there any API which can provide validation for such mismatches beforehand based on database used.

      eg. integer -> varchar      --      allowed 

            varchar -> boolean    --      not allowed

      Teiid handle scenario 1 by itself and throws an error at runtime in case of scenario 2. I want to know these validations before firing the actual query.

       

      Regards,

      Pranita G