Questions tagged [db2]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
14
votes
2answers
866 views

How does this shebang that starts with a double hyphen (--) work?

I have found the following kind of shebang in the RosettaCode page: --() { :; }; exec db2 -txf "$0" It works for Db2, and a similar thing for Postgres. However, I do not understand the whole line. ...
1
vote
1answer
635 views

Passing parameters inside db2 SQLs from an unix shell script

I want to delete certain rows from a table based on my input values to a unix shell script. I am making connections and terminating it inside my shell script. If you notice right now the field is ...
1
vote
0answers
88 views

Permissions confusion when executing binaries via script

ls -al /home/dmsinst1/sqllib/adm/db2start -r-sr-sr-x 1 root dmsiadm1 93613 Jun 26 14:14 /home/dmsinst1/sqllib/adm/db2start ls -al /home/bpminst1/sqllib/adm/db2start -r-sr-sr-x 1 root bpmiadm1 93613 ...
-1
votes
1answer
455 views

db2start fails with error while loading shared libraries: libstdc++.so.5: cannot open shared object file: No such file or directory

Installed db2 10.5 but installation completes with warning that db2start failed while loading shared libraries: libstdc++.so.5: cannot open shared object file: No such file or directory. i have both ...
2
votes
0answers
137 views

IBM DB2 for Linux AMD64 does not install on Debian Jessie, installer log suggests issue with IBM-supplied libdb2ure.so

I have a ThinkPad T430 with 8 GB RAM and an Intel Core i5 3320M running Red Hat Enterprise Linux 6.7 using kernel 2.6.32-642, and a KVM-QEMU VM running Debian Jessie for AMD64 with kernel 3.16.0-4, ...
0
votes
2answers
201 views

Which DB2 client package is needed to compile embedded SQL programs?

I have to work on some embedded SQL files (.sqc) for DB2 which will be compiled on Linux. The DB2 command line processor (db2 command) has to be used for precompilation. What of the many DB2 client ...
1
vote
2answers
4k views

Database: 0403-009 The specified number is not valid for this command [closed]

getting the error as Database: 0403-009 The specified number is not valid for this command. Code:: #!/usr/bin/ksh #set -x WORKFILE="/tmp/oatest.out" DDLFILE="/tmp/oatest.ddl" TODOFILE="/tmp/...
1
vote
3answers
2k views

Execute a database query by iterating through results of a previous query

I'm new to Unix and bash scripts so please bare with me if this is a silly question. I've just started working for a company that uses DB2 hosted on a Unix platform and there are a lot of unwanted ...
1
vote
2answers
1k views

su -c command fails when sending db2 commands

I have a script I've setup to run a number of tasks, one of which is to set up a table in a DB and later remove it (for automated testing). The issue comes that on only a few of the users that I use ...
2
votes
1answer
3k views

Storing longer text output in memory in shell variables vs Writing to disk

I have the below call to db2 database command line tool inside a loop, which runs 100k iterations. (the output from db2 is 5 rows of 20 chars approx per each call, total of approx 100k calls. The ...
1
vote
1answer
1k views

Confusing db2 output

When type in echo $(db2 -x "select count(*) from dict_area") in bash, I get 446. But when I type in echo $(db2 -x "select count(*) from dict_area";db2 -x "select count(*) from dict_area"), I get ...
2
votes
3answers
795 views

How Do I install DB2 Remotely?

I have been trying to install IBM DB2 10.5.0.1 on AIX 7.1.0.0 from a Windows 8-64bit using a Remote connection. It has been 3 days and I haven't been able to succeed; Here is a list of everything I've ...
1
vote
1answer
2k views

How to install IBM DB2 Database Driver on Ubuntu for Node.js

I need assistance installing IBM DB2 drivers onto Ubuntu. Using Ubuntu 14.04, I'm attempting to create a simple web page that gets served by the node.js server-side framework. A server-side-...