Hi
I have written on stagevariable but it is giving me wrong result can any help me on this
mystagevariable if trans.empno=mast.empno then 1 else 0
both columns are varchar columns
trans.empno=00000802 (value coming from hash file)
mast.empno=802 (value coming from oracle stage)
but data stage shows both are same i am wondering how?
Thanks in advance
Error in stagevariable
Moderators: chulett, rschirm, roy
Re: Error in stagevariable
Hibasu.ds wrote:Hi
I have written on stagevariable but it is giving me wrong result can any help me on this
mystagevariable if trans.empno=mast.empno then 1 else 0
both columns are varchar columns
trans.empno=00000802 (value coming from hash file)
mast.empno=802 (value coming from oracle stage)
but data stage shows both are same i am wondering how?
Thanks in advance
Hope ur issue is resolved by now
Anyway, i think the problesm here is with datatypes.
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
There is no problem - they are the same.
In server jobs there are no data types. So a comparison tests each operand to determine whether or not they are numeric. If they are, a numeric comparison is performed - if not, a string comparison is performed.
To force a string (or numeric) comparison use the Compare() function, or force each operand to be a string by concatenating the same non-numeric string to each.
In server jobs there are no data types. So a comparison tests each operand to determine whether or not they are numeric. If they are, a numeric comparison is performed - if not, a string comparison is performed.
To force a string (or numeric) comparison use the Compare() function, or force each operand to be a string by concatenating the same non-numeric string to each.
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.