By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
454,235 Members | 1,464 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 454,235 IT Pros & Developers. It's quick & easy.

cygwin - db2 v9 on windows

P: n/a
Hello,
I would like to execute bash scripts under windows calling db2* stuff.
Some time ago there was thread on cygwin and db2, and some solutions
presented there and tested by me worked on db2 v8. Unfortunatelly in
db2 v9 I cant find any db2ntclp. When I run bash within db2cmd, after
establishing connection consecutive calls of db2 cause error "SQL1024N
A database connection does not exist.".
Has anyone tested succesfully differenct strategy with cygwin and db2
v9 on wintel?

Thanks,
Bart

Oct 11 '06 #1
Share this Question
Share on Google+
3 Replies


P: n/a
I have the same issue of cygwin bash not working with DB2 V9. DB2 V9,
unlike V8, resets connection after each bash command. This made all my
shell scripts unusable. Please post a message to the group if you have
figured out a work-around.

Thanks

P Adhia.

On Oct 11, 7:41 am, "bart111111" <bartn...@gmail.comwrote:
Hello,
I would like to execute bash scripts under windows calling db2* stuff.
Some time ago there was thread oncygwinand db2, and some solutions
presented there and tested by me worked on db2 v8. Unfortunatelly in
db2 v9 I cant find any db2ntclp. When I run bash within db2cmd, after
establishing connection consecutive calls of db2 cause error "SQL1024N
A database connection does not exist.".
Has anyone tested succesfully differenct strategy withcygwinand db2
v9 on wintel?

Thanks,
Bart
Nov 30 '06 #2

P: n/a
In article <11**********************@n67g2000cwd.googlegroups .com>,
pa****@yahoo.com says...
I have the same issue of cygwin bash not working with DB2 V9. DB2 V9,
unlike V8, resets connection after each bash command. This made all my
shell scripts unusable. Please post a message to the group if you have
figured out a work-around.

Thanks

P Adhia.
I've had a problem with Viper on Windows XP using Object REXX which
looks like the same kind of problem.
You can find the discussion in the DB2 V9 forum at developersworks at he
wrapped link:
http://www-128.ibm.com/developerwork....jsp?forum=842
&thread=114450&cat=19

or http://tinyurl.com/fwf66

For Rexx on windows a workaround is available as you can see in the
above link but I don't know if it also works for the bash shell.

Nov 30 '06 #3

P: n/a
You can find the discussion in the DB2 V9 forum at developersworks at he
wrapped link:http://www-128.ibm.com/developerwork....jsp?forum=842
&thread=114450&cat=19
You nailed it!! Thank you. I just tested it and it worked after setting
the DB2CLP variable. Now I am in the same boat as you are in. Modify
all my shell scripts to make this change. Even worse, now I cannot
share shell scripts between windows and unix any more without some
fancy environment check.

I agree with you completely, scripting languages don't call C APIs,
they call commands and parse the output. If IBM's position is that DB2
CLP is an "application" rather than "interface", then I'd say, it's a
pretty useless application. Very few real life scenarios involve
writing application as a sequence of SQLs to be run unconditionally one
after another -- which is about the most CLP can do.

P Adhia

Nov 30 '06 #4

This discussion thread is closed

Replies have been disabled for this discussion.