Have been playing/experimenting with mobaXterm (v4.2 already there). I found a way to access db2 using this shell instead of the db2cmd box.
I created a script in the home dir called prepareDB2.sh
Code:
export PATH=${PATH}:~/drives/c/ibm/sqllib/bin/
export DB2INSTANCE=db2
export DB2CLP=**$$**
db2set db2dbdft=sample
This script must be executed like this (after chmod +x prepareDB2.sh)
and then you can type
Code:
db2 "select * from employee"
Because I am bound to use the "db2set db2dbdft=sample" option the functionaly is limited to databases which you can access without specifying your userid/passwd. But the result so far is nice
(when I try ". db2 connect to sample" (notice the 'dot space' preceding the db2 command) to prevent the subshell issue I get a strange error: bash: $'MZ\220': command not found. (
almost the same as the motorcycle I used to drive many years ago (motorencyclopedie****/motorencyclopedie/mz-ts250-1/ts250-1) I know: ugly bike but that was the only thing I could afford back then))
Can somebody smarted than me help to figure this out?