Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
upaliwije
Creator II
Creator II

IF & MATCH

Hi,

I have following lines in my data load script

  if(TXN_TYPE=1,REF_NO) AS DEBIT_NOTE_NO,

     if(TXN_TYPE=2,REF_NO) AS SETT_REC_NO,

     if(TXN_TYPE=4,REF_NO) AS REFUND_SLIP_NO,

     if(NOT MATCH(TXN_TYPE,1,2,4,REF_NO)) AS OTHERS,

But the last line does not work . What I want is if TXN_TYPE<>1,2,4 the REF_NO should be others

Pls help me to correct abobe error

1 Solution

Accepted Solutions
sunny_talwar

May be try this:


If(not Match(TXN_TYPE,1,2,4),REF_NO) AS OTHERS,

View solution in original post

4 Replies
sunny_talwar

May be try this:


If(not Match(TXN_TYPE,1,2,4),REF_NO) AS OTHERS,

jonathandienst
Partner - Champion III
Partner - Champion III

Is this what you are after?


if(MATCH(TXN_TYPE,1,2,4) = 0, REF_NO) AS OTHERS,

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
vinieme12
Champion III
Champion III

Try with quotes

if(MATCH(TXN_TYPE,'1','2','4')=0,REF_NO)) AS OTHERS,

Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.
Anonymous
Not applicable

may be this?

if(TXN_TYPE<>1 or TXN_TYPE<>2 or TXN_TYPE<>4 ,REF_NO) AS Others