Sponsored Content
Full Discussion: DB2 - Tracking Table history
Top Forums Programming DB2 - Tracking Table history Post 303009676 by rbatte1 on Monday 18th of December 2017 08:57:50 AM
Old 12-18-2017
In Oracle, this would be best done with a trigger. This fires on the conditions you set and can write an audit trail, however you have to be careful about the impact of enabling them because IO can be hit quite badly (capacity and performance)

There is a similar facility for DB2. Try an internet search for "DB2 trigger" and see if that helps.

From there it should just be a simple report to run as required to get the information based on what you saved.



Robin
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

How to connect DB2 table using shell script

Hi All, I want to connect two tables in DB2 using shell script and then compare the contents of two tables field by field. Could any one please help me in connecting database tables using Unix and retriving data from the same. Thanks, Durwas (0 Replies)
Discussion started by: dtidke
0 Replies

2. Shell Programming and Scripting

Export data from DB2 table to .txt file(space delimited)

Hi I need help on this. Its very urgent for me.. please try to help me out.. I have data in tables in DB2 database. I would like to export the data from DB2 tables into a text file, which has to be space delimited. so that I can carry out awk, grep operations on that file. I tried to export... (2 Replies)
Discussion started by: ss3944
2 Replies

3. Shell Programming and Scripting

Connect to DB2 table using Shell scripts

Can anyone please help me with an unix shell script to connect a DB2 database. My requirement is just to display the no of records present in a table of a DB2 database through Unix Shell script. Thx - Ram (1 Reply)
Discussion started by: onlyraja
1 Replies

4. Shell Programming and Scripting

select values from db1 table and insert into table of DB2

Hi I am having three oracle databases running in three different machine. their ip address is different. from one of the DB am able to access both the databases.(means am able to select values and insert values in to tables individually.) I need to fetch some data from DB1 table(say DB1 ip is... (2 Replies)
Discussion started by: aemunathan
2 Replies

5. Shell Programming and Scripting

Read parameter file in a shell script to unload a DB2 Table???

Hi , I Have following requirement: DB2 Sql query to pass from a parameter file for example, I would create a parameter file with (SELECT column 1, column 2 FROM Table name) then job would read it and create a file with the contents named table.txt How to write/modify below ksh script to... (10 Replies)
Discussion started by: developer.dwh9
10 Replies

6. Red Hat

Tracking All session history in one file

Dear All, I want to keep all the session history in one file,please help me out to configure so. Here is the test scenario- Suppose i have three client A,B and C tries to log in to one Server XA there session specific command and Clint IPADDRESS should get logged in one file...like ... (0 Replies)
Discussion started by: monojcool
0 Replies

7. Shell Programming and Scripting

Tracking users through history command

Hi folks, I have the basic query that there are 3 unix boxes having their individual access now in my team there are 4 members who are using the same credentials to access those 3 boxes through putty ssh from their windows desktop , now if i want to check which 4 members have executed the... (1 Reply)
Discussion started by: punpun66
1 Replies

8. Programming

DB2 Query to check table counts,start end time

Dear team I am using DB2 and wish to capture the ETL status on daily basis so that i can run the query and share the details in xls format to respective mail ids . Currently i am using below query but this displays table name and counts for latest run. select name ,CARD from... (0 Replies)
Discussion started by: Perlbaby
0 Replies

9. Shell Programming and Scripting

Python Script to take file count and insert into DB2 table

Team I have files in different directories . How can i take the count of latest file and insert into Db2 table . I am using awk 'END{print NR+1-ARGC}' (File name) to get the counts. How can i take 1.The count of latest file 2.Insert into Db2 table( File Name and Counts) . cd... (4 Replies)
Discussion started by: Perlbaby
4 Replies

10. Programming

DB2 z/os How to Track table delete Activities

Dear Team I am using DB2 v10 z/os database . Need expert guidance to figure out best way to track table activities ( Ex Delete, Insert,Update ) Scenario We have a table which is critical and many developer/testing team access on daily basis . We had instance where some deleted entire table .... (1 Reply)
Discussion started by: Perlbaby
1 Replies
PDO_IBM-DSN(3)								 1							    PDO_IBM-DSN(3)

PDO_IBM DSN - Connecting to IBM databases

	The PDO_IBM Data Source Name (DSN) is based on the IBM CLI DSN. The major components of the PDO_IBM DSN are:

	      o DSN prefix
		- The DSN prefix is ibm:.

	      o DSN
		- The DSN can be any of the following:

		     o a) Data source setup using
		       db2cli.ini or odbc.ini

		     o b) Catalogued database name i.e. database alias in the DB2 client catalog

		     o c) Complete connection string in the following format: DRIVER={IBM DB2 ODBC DRIVER};DATABASE=
		       database;HOSTNAME=  hostname;PORT= port;PROTOCOL=TCPIP;UID= username;PWD= password; where the parameters represent the fol-
		       lowing values:

			    o $database
			      - The name of the database.

			    o $hostname
			      - The hostname or IP address of the database server.

			    o $port
			      - The TCP/IP port on which the database is listening for requests.

			    o $username
			      - The username with which you are connecting to the database.

			    o $password
			      - The password with which you are connecting to the database.

       Example #1

	      PDO_IBM DSN example using db2cli.ini

	       The following example shows a PDO_IBM DSN for connecting to an DB2 database cataloged as DB2_9 in db2cli.ini:

	      $db = new PDO("ibm:DSN=DB2_9", "", "");

	      [DB2_9]
	      Database=testdb
	      Protocol=tcpip
	      Hostname=11.22.33.444
	      Servicename=56789

       Example #2

	      PDO_IBM DSN example using a connection string

	       The following example shows a PDO_IBM DSN for connecting to an DB2 database named testdb using the DB2 CLI connection  string  syn-
	      tax.

	      $db = new PDO("ibm:DRIVER={IBM DB2 ODBC DRIVER};DATABASE=testdb;" .
		"HOSTNAME=11.22.33.444;PORT=56789;PROTOCOL=TCPIP;", "testuser", "tespass");

PHP Documentation Group 													    PDO_IBM-DSN(3)
All times are GMT -4. The time now is 04:26 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy