Hi friends
I am new to Datastage and i am in the process of learning.
My question is can we use a EndIf in the derivation part of Transformer.
For example if i dont have a condition for Else would datastage accept it.
thanks in advance
aakash
Can i use EndIf in derivation of transformer????
Moderators: chulett, rschirm, roy
-
- Charter Member
- Posts: 24
- Joined: Sun Nov 13, 2005 10:59 pm
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
No.
The If..Then..Else in an expression is a conditional expression, not a conditional statement. A conditional expression generates one of two values, depending on the result of a test expression. Therefore you must have both a Then clause and an Else clause in an conditional expression.
Further, there is no EndIf in DataStage BASIC. A block of statements introduced by Then or Else as the final token on its line is terminated by an End statement (not an EndIf statement). But this can not be used in an expression, only in a routine.
The If..Then..Else in an expression is a conditional expression, not a conditional statement. A conditional expression generates one of two values, depending on the result of a test expression. Therefore you must have both a Then clause and an Else clause in an conditional expression.
Further, there is no EndIf in DataStage BASIC. A block of statements introduced by Then or Else as the final token on its line is terminated by an End statement (not an EndIf statement). But this can not be used in an expression, only in a routine.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.