473,408 Members | 2,832 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,408 software developers and data experts.

Copy DB2 Sequence number from Production to Test

Would like to know is there an automated way to copy the maxvalue of sequence number from db2 production to db2 test.
When we copy data from our production that uses a sequence number value as its unique key into test, we get problems doing inserts in test unless we also manually update the test.sequence to be equal to or greater than the production.sequence number.

Can this manual process be automated by a utility or something simple?
Currently we do this manually through two steps:
1) select production.sequence to get the current value which might be 183500
2) then in test.
ALTER SEQUENCE EPIC
RESTART WITH 183500,INCREMENT BY 1,
MINVALUE 0,MAXVALUE 2147483647,NO CYCLE,CACHE 1000;
Jan 15 '08 #1
0 2071

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: len | last post by:
I am in a situation where I need to get a copy of test database that is on production server running MSSQL 2000 Standard to my local machine running MSSQL 2000 personel. I tried to use the copy...
6
by: Fan Ruo Xin | last post by:
I try to copy a table from production system (DB2 UDB EEE V7.2 + fixpak5) to the testing system (DB2 UDB V8.1 + fixpak4a). I moved the data from productions system by using the following steps:...
3
by: Balaji Pooruli | last post by:
Hi, I have a critical requirement. I did search in the forums, but still I am not clear. Here is the requirement. Our Project (ACE) has nearly 400 DB2 tables in production and Test...
1
by: Adrian | last post by:
Hi all Initial postion: IIS 6.0, Windows 2003 Server, .NET Framework 1.1 We have a development Server A, a stating Server B and a production Server C. After development of the .NET ASP...
5
by: zgh1970 | last post by:
Hi, We have some tables with db2 generated field. How can I find the next generated sequence fot those fields. Thanks,
1
by: aj | last post by:
DB2 LUW 8.2 FP14 Red Hat AS 2.1 I went to restore a backup of my production DB on my test/developmental server. The backup on the prod system was taken /before/ alt_obj() was used there to do...
5
by: Steve | last post by:
Hi; I thought I would rephrase a question I asked in another post to more quickly get to the heart of the matter. My apologies for anyone who is offended by what appears to be a repetition. ...
13
by: stef mientki | last post by:
hello, I generate dynamically a sequence of values, but this "sequence" could also have length 1 or even length 0. So I get some line in the form of: line = '(2,3,4)' line = '' line = '(2)'...
1
by: altaey | last post by:
Question Details: Write a program to find and print a Fibonacci sequence of numbers. The Fibonacci sequence is defined as follow: Fn = Fn-2 + Fn-1, n >= 0 F0 = 0, F1 = 1, F2 = 1 Your...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.