-
sequences
Hy,
I am new to the forum, and already have problems.
I'm running on Oracle 805 server on win2k.The problem is:
my sequnces in db are created using the next rule
xx||yy||zz||aaaaaaa, where x,y,z,a are numbers, more, when i select
them from the db(via sql) the string which is returning to me looks like
xxyyzzaaaaaaa.(they should look like exactly like this,the xxyyzz must remain fixed as value, while aaaaaaa must grown in range with the number provided by increment by value which is normaly assigned between 1 to 20). For some of them the value of the increment by parameter is too large(ie 30000) and therefore the value which i'm getting back in my programs is altered.The nextval param. does not respect anymore, the string above.(the initial xxyyzzaaaaaaa string has became uuvvttbbbbbbb, because of increment by param., which is too big in that case.)
My question is: is there a way to recreate the sequences without damaging the informations which is related to this sequences?Excluding the create like method.
-
You've lost me totally
Can you post the CREATE SEQUENCE statement you used, the output from a "SELECT sequence_name.NEXTVAL FROM dual" statement and the result you would like to see.
Cheers
Tim...
-
Originally Posted by eto_toe_dba
My question is: is there a way to recreate the sequences without damaging the informations which is related to this sequences?
The sequence numbers stored in the table are not linked in any way to the sequence itself - they won't change unless you explicitly update them.
Yes, you can recreate your sequence. BUT you will have to ensure somehow that you won't generate any duplicate values if this is (e.g.) a primary key.
"The power of instruction is seldom of much efficacy except in those happy dispositions where it is almost superfluous" - Gibbon, quoted by R.P.Feynman
-
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|