This should be simple, and the docs say so, but no...
1) I have an .hta file (VBScript), with a call to windoze shell
2) the shell call is to db2cmd, input from a file
3) the command file has a db2 SELECT <blah command
If I insert foo.txt in the db2cmd command line, the
commands, result set, and messages go to foo.txt. That's sort
of OK, except that running EXPORT, i can concoct the command
with a file for output, and the result goes there. The client
wants both the SELECT and EXPORT to work the same: result
set in a file.
The docs say that I can insert -r foo.txt in either the
db2cmd command line or the db2 command line, and get the
result of the SELECT in foo.txt. Nope. Windoze creates foo.txt,
but db2 errors with "unable to access file".
I don't think it should be so difficult. Nothing at the DB2 site
that I could find explains why this doesn't work.
winXP/SP2, UDB v8.2.9
1) I have an .hta file (VBScript), with a call to windoze shell
2) the shell call is to db2cmd, input from a file
3) the command file has a db2 SELECT <blah command
If I insert foo.txt in the db2cmd command line, the
commands, result set, and messages go to foo.txt. That's sort
of OK, except that running EXPORT, i can concoct the command
with a file for output, and the result goes there. The client
wants both the SELECT and EXPORT to work the same: result
set in a file.
The docs say that I can insert -r foo.txt in either the
db2cmd command line or the db2 command line, and get the
result of the SELECT in foo.txt. Nope. Windoze creates foo.txt,
but db2 errors with "unable to access file".
I don't think it should be so difficult. Nothing at the DB2 site
that I could find explains why this doesn't work.
winXP/SP2, UDB v8.2.9
Comment