Pseudo Code
Variable: myVar=abc,def,xyz
for each myVar
FTP
endfor
How can I achieve this.. I can use either of the loop options (Do, While or For), and the variable is under our control,
We can use Comma Seperated, or, If its not possible even XML would be fine..
Just need a way to manipulate loops using variables.....
String to RowSet to use in a Loop
Post any question you may have in regards to GoAnywhere Director and let our talented support staff and other users assist you.
- Support_Duane Offline
- Support Specialist
- Posts: 66
- Joined: Thu Mar 05, 2009 3:49 pm
Re: String to RowSet to use in a Loop
GoAnywhere does not currently (as of July 2010) allow string operations on variables, so you cannot pass in a string and use pieces of it in your loop. What you can do, however, is to place the values into separate records in a file, (any of the file types that GoAnywhere can read - Database, CSV, Fixed Width, Excel, XML) read that file, then set up a For Each loop based on the value in each record.
Re: String to RowSet to use in a Loop
Hello Team,
Could you please let us know whether this feature implemented in the latest version as of 28th Sep-2016.
Thanks
Could you please let us know whether this feature implemented in the latest version as of 28th Sep-2016.
Thanks
- Support_Rick Offline
- Support Specialist
- Posts: 590
- Joined: Tue Jul 17, 2012 2:12 pm
- Location: Phoenix, AZ
- Contact:
Re: String to RowSet to use in a Loop
Yes, there have been many improvements to the product since July, 2010. Please check out the Release Notes on MFT and Director to see the progression and how this has grown.
Rick Elliott
Lead Solutions Consultant
(402) 944.4242
(800) 949-4696
Lead Solutions Consultant
(402) 944.4242
(800) 949-4696
Re: String to RowSet to use in a Loop
Hi Rick,
We are using Version 5.1.5. I dont see the option for string splitting.
We are using Version 5.1.5. I dont see the option for string splitting.
- Support_Rick Offline
- Support Specialist
- Posts: 590
- Joined: Tue Jul 17, 2012 2:12 pm
- Location: Phoenix, AZ
- Contact:
Re: String to RowSet to use in a Loop
We've had several enhancements .. but, not this specifically.
As Duane mentioned above, it can be accomplished by writing the values out to a CSV (etc) then reading them into a RowSet variable, then looping that RowSet.
Pseudo Code:
As Duane mentioned above, it can be accomplished by writing the values out to a CSV (etc) then reading them into a RowSet variable, then looping that RowSet.
Pseudo Code:
Code: Select all
Print -> Temp.csv
CDATA[[
${var1},${system.carriageReturn}
${var2},${system.carriageReturn}
${var3},${system.carriageReturn}
]]
ReadCSV (Temp.csv) -> MyRowset
ForEach ${MyRowset} -> Rec
call FTP parm resourceID=${Rec[1]}
endForEach
Rick Elliott
Lead Solutions Consultant
(402) 944.4242
(800) 949-4696
Lead Solutions Consultant
(402) 944.4242
(800) 949-4696