I tried to trim both leading and trailing spaces in a single specification of modify stage before but it did not work.ajith wrote:
I tried that too,
It is trimming only the trailing spaces not the leading ones.
I seriously don't know what to do now, I have to do Trimming on 3 source feeds. I hate modify stage, it allows me to do nothing. Dont tell me the only way forward is adding 3 transformer stages.
Trim Function in Modify Stage
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Have you tried two functions?
Code: Select all
string_trim[" ",begin](string_trim[" ",end](MyString))
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.
Thanks Ray.ray.wurlod wrote:Have you tried two functions?Code: Select all
string_trim[" ",begin](string_trim[" ",end](MyString))
I tried the above code and got the following error:
main_program: Error parsing modify adapter: Error in binding: Error in source field selector: Expected integer, got: "" ""
Expected destination field selector, got: ")"; input:
Col2=string_trim[" ",begin](string_trim[" ",end](Col1))
;
ray.wurlod wrote:Have you tried two functions?...Code: Select all
string_trim[" ",begin](string_trim[" ",end](MyString))
It does not allow me to combine two commands.
I get the same error as Balaji gets
The modify stage doesn't allow combining commands
<a href=http://www.worldcommunitygrid.org/team/ ... TZ9H4CGVP1 target="WCGWin">
</a>
</a>
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
-
- Participant
- Posts: 222
- Joined: Tue Aug 30, 2005 2:07 am
- Location: pune
- Contact:
Hi All,
Final Conclusion from this disscussions is , it is not possible to trim leading and trailing spaces by using Modify stage. It is possible only through Transformer stage. So, can I ask DS gurus, can we ask this functionality in the next release of datastage to IBM. If the above conclusion is right. I am asking to all, If anybody got the answer of TrimLeading and Trailing by using modify stage, please let us know, other wise, we will raise this with IBM.
Final Conclusion from this disscussions is , it is not possible to trim leading and trailing spaces by using Modify stage. It is possible only through Transformer stage. So, can I ask DS gurus, can we ask this functionality in the next release of datastage to IBM. If the above conclusion is right. I am asking to all, If anybody got the answer of TrimLeading and Trailing by using modify stage, please let us know, other wise, we will raise this with IBM.
NageshSunkoji
If you know anything SHARE it.............
If you Don't know anything LEARN it...............
If you know anything SHARE it.............
If you Don't know anything LEARN it...............