Search code examples
etldecodeinformatica-powercenteriif-function

informatica : why i am getting error while using iif function?


I have column 'GENDER' where values 'M or 'F' comes in , anyother value coming, i want to populate as 'UNK' using IIF in expression tranf informatica. i am getting error

operand cannot be converted to number

using below expression

iif(GENDER='M' OR 'F','TRUE','UNK')

Solution

  • Please use this code

    iif(GENDER='M' OR GENDER='F',GENDER,'UNK')
    

    if its M or F then use original column else populate UNK.