4 Replies Latest reply on Apr 16, 2013 3:50 PM by SriniVEERAVALLI

    Union of non-compatible types

      Hi, I am trying to do a simple CASE WHEN statement and I keep getting this error. "Union of non-compatible types"

      Below is the SQL I am using to get the desired results. Can anyone tell me why I would be getting this error. My goal is to simply apply the math only when the condition are met.

      CASE WHEN "Pending Claim - End Product"."End Product Code" IN ('687','681','405')
      AND "Pending Claim - Process Time"."Claim Date" < date '2010-10-30'
      THEN SUM("Pending Claim - Process Time"."Days Pending"+ TIMESTAMPDIFF(SQL_TSI_DAY, date '2010-10-30', "Pending Claim - Process Time"."Claim Date"))
      ELSE "Pending Claim - Process Time"."Claim Date" END