Posted: Fri Mar 13, 2009 5:51 pm
For the sake of our sanity, can you explain in words what this routine is meant to accomplish / return? I really don't want to infer anything based on a reading of the code.
Code: Select all
DebugMsg = "Arg 1 = " : Quote(Convert(@FM:@VM:@SM:@TM,'~}|{',Arg1)
Call DSLogInfo(DebugMsg, "Debugging")
What i am trying to do is get the position numbers for a given multi-valued column. Eg: Arg1 = (ABC~DEF~GHI~JKL ) Then i want the return to be 1:2:3:4.chulett wrote:For the sake of our sanity, can you explain in words what this routine is meant to accomplish / return? I really don't want to infer anything based on a reading of the code.
The situation is that a Value Mark in UniVerse is being treated as an @SVM in DataStage. I created this routine in UniVerse and modified it so that it can be run in Datastage. however there are some issues with the DataStage engine. Clifton from IBM was here the other day and he gave me another Convert funtion called RAISE which is not recognized by DataStage but compiles fine and runs great.ray.wurlod wrote:How do you know you're processing the correct level of delimiter? For example Char(252) is - probably - a sub-value mark, while Char(253) is - probably again - a value mark. Some operations, such as Trans() with a multi-valued first argument, effect an automatic Lower() on the dynamic array. Add debugging statements to determine precisely what delimiter character is in Arg1.Code: Select all
DebugMsg = "Arg 1 = " : Quote(Convert(@FM:@VM:@SM:@TM,'~}|{',Arg1) Call DSLogInfo(DebugMsg, "Debugging")
I have not passed any @VM or @SM expressions. i have passed the equivalent delimiters that are provided by the view data from DataStage. This shows that DataStage masks @VMs as @SVMs which is incorrect and the Test part of Datastage also suffers from the same problem....chulett wrote:I'd be surprised if you could actually pass @SM or @VM characters into the test harness correctly.
Which is exactly what I meant.rachit82 wrote:I have not passed any @VM or @SM expressions. i have passed the equivalent delimiterschulett wrote:I'd be surprised if you could actually pass @SM or @VM characters into the test harness correctly.
Code: Select all
argArg1 = Arg1
Counter = 0
Ans = ""
Loop
Remove Element From argArg1 Setting Delim
Counter += 1
Ans := Element : Char(256 - Delim)
While Delim
Repeat