I am writing the launch plan for one of my code. In which, for each step i have to write a verification step which will tell if the deployment/change has been made properly. Like if there is an alter table command to add a new column then as a verification, I would be using select column_name from table as verification step.
I am looking for a verification step for my sequence script. My sequence scripts is dropping the old sequence and re-creating it with initial value changed. lets say if my last sequece was on 10071 – the new sequece would start from 100710.
I wrote the following query
SELECT LAST_NUMBER
FROM all_sequences
WHERE sequence_name = 'SEQNAME';
Now, my question is, would that give the last number of my new sequence or the old sequence?
P.S:
I can’t use sequence NextValue – it would cause the system to miss 1 number and will mess up the whole system. However, I am open for the options in which my *next_value* can be utlizied, automatically.
Err … Why not just try it as suggested by Randy in the comments ?