Need to preserve Generated ALWAYS UPDATE Row Value when loading to another DB2 Environment

Paul Kautza

Need to preserve Generated ALWAYS UPDATE Row Value when loading to another DB2 Environment
For z/OS DB2 V9: The 'GENERATED ALWAYS FOR EACH ROW ON UPDATE AS ROW CHANGE TIMESTAMP' column must be ignored when unloading a production version of a table then loading to test. The result is CURRENT TIMESTAMP as the table is being loaded. Does anyone know a way of preserving the column values from production. We considered, but disregarded DSN1COPY. Thanks.

_________________________________________________________________

Register NOW for the IDUG DB2 Tech Conference in Anaheim, May 2-6, 2011!
_________________________________________________________________
If you need to change settings, http://www.idug.org/cgi-bin/wa?A0=DB2-L
is the home of IDUG's Listserv

Robert Yoder

Re: Need to preserve Generated ALWAYS UPDATE Row Value when loading to another DB2 Environment
(in response to Paul Kautza)
Hi Paul

From the DB2 9 utility manual

To include the data from the ROWID, identity, or row change timestamp
| column when you load the unloaded data into a table, define the ROWID,
| identity, or row change timestamp column with GENERATED BY DEFAULT. To use
| the generated LOAD statement, remove the IGNOREFIELDS keyword and change
| the dummy field names to the corresponding column names in the target
| table.

Bob Yoder
Archer Daniels Midland Co.
IBM Tech Support(GTC)
217.451.3787

-----Original Message-----
From: IDUG DB2-L [mailto:[login to unmask email] On Behalf Of Paul Kautza
Sent: Wednesday, May 11, 2011 9:49 AM
To: [login to unmask email]
Subject: [DB2-L] Need to preserve Generated ALWAYS UPDATE Row Value when loading to another DB2 Environment

For z/OS DB2 V9: The 'GENERATED ALWAYS FOR EACH ROW ON UPDATE AS ROW CHANGE TIMESTAMP' column must be ignored when unloading a production version of a table then loading to test. The result is CURRENT TIMESTAMP as the table is being loaded. Does anyone know a way of preserving the column values from production. We considered, but disregarded DSN1COPY. Thanks.

_________________________________________________________________

Register NOW for the IDUG DB2 Tech Conference in Anaheim, May 2-6, 2011!
_________________________________________________________________
If you need to change settings, http://www.idug.org/cgi-bin/wa?A0=DB2-L
is the home of IDUG's Listserv

CONFIDENTIALITY NOTICE:
This message is intended for the use of the individual or entity to which it is addressed and may contain information that is privileged, confidential and exempt from disclosure under applicable law. If the reader of this message is not the intended recipient or the employee or agent responsible for delivering this message to the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communication in error, please notify us immediately by email reply.



_________________________________________________________________

Register NOW for the IDUG DB2 Tech Conference in Anaheim, May 2-6, 2011!
_________________________________________________________________
If you need to change settings, http://www.idug.org/cgi-bin/wa?A0=DB2-L
is the home of IDUG's Listserv