Hello All:

ARS: 7.1 P4
Platform: Windows 2003 Server

I'm running into an issue where I am running a script that adds data to a 
csv file. I'm using the SED command (for windows, GNUWin32) to perform the 
substitution. 

Basically what this script does is append a column header and Request ID 
to the data file using SED and then imports the data file:

START:
cd /d %9

sed s/$/,%1/g %~7 > tempfile.csv

sed 1s/%1/IMPORTID/ tempfile.csv > %~7

%2 -u %3 -p %4 -m %5 -d %6 -l "%~8\%~7.log" -o "%~9\%~7" -x <server name>

Del tempfile.csv

END:

Where %1 is the Request ID and %7 is the file name. ARS is installed on 
the D drive whereas the data file is pushed to the C drive. When run thru 
a Run Process action, the tempfile.csv created in the first sed command 
ends up empty and therefore the original file (%7) also ends up empty. But 
if I run the command from the commandline it works fine. Just not thru 
Remedy. I even ran a test of pushing the data file to the D drive (D:\AR 
System) and running sed from there but same result.

Added the following to the script after the cd /d %9 command:

copy %7 importdatafile.csv

The copy command works fine and does copy the file and its contents fine 
thru Remedy's Run Process so it is not a delay issue of the data file 
being transferred.

Has anyone ever run into this type of behaviour before. Any assistance 
would be greatly appreciated. Thanx in advance

Have a great day

ciao

john

_______________________________________________________________________________
UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
attend wwrug10 www.wwrug.com ARSlist: "Where the Answers Are"

Reply via email to