Re: Problem importing sequences
Date: 1996/02/28
Message-ID: <1996Feb28.163305.5472_at_nosc.mil>#1/1
In article <4g5lij$7sr_at_newsbf02.news.aol.com>, markp10013_at_aol.com (MarkP10013) says:
>
>Here's my problem: I'am trying to copy a database from one machine to
>another by first exporting from the source machine at the user level and
>then importing on the target machine at the same user level. Everything
>goes well. (import successful with warnings) The row counts are the same,
>but the sequences are not updated. What could be causing this to happen?
>
My boss has the same problem when importing from our development platform (HP 9000, v7.1.6) to his laptop (v7.1.4). He very diligently drops all other objects that he knows have changed since the last import, but he ALWAYS forgets about sequences. And, since he has trouble with them, he's always claiming this is a really good reason NOT to use sequences!
Anyway...when we import, we typically set 'ignore=y' so that import does not give us an error message saying that a table or index or SEQUENCE exists. Have you ever noticed that if you attempt to import to a PK-constrained table you get constraint violation error messages? Oracle is telling you 'you can't do that'. With a sequence, however, if the sequence exists then nothing happens, because there are no rows to import, and no constraint to violate, hence no message.
You have two alternatives...1) drop the sequences before you import, or 2) build a SQL or PL/SLQ script to update the sequences afterwards.
HTH
Mike Vergara
mvergara_at_sctcorp.com
Received on Wed Feb 28 1996 - 00:00:00 CET