We've been using sequence numbers in our Oracle 10g database with the folowing code:
--CREATE THE SEQUENCE FOR THE PRIMARY KEY
CREATE SEQUENCE [SCHEMA].[PK]_SEQ
START WITH 1
INCREMENT BY 1
MINVALUE 1
NOCACHE
NOCYCLE
ORDER;
The challenge is to create a sequence using the current year in the following format: FY9999
Where FY = "fiscal year", in this case it would be 08. Next year it would be 09. Then the next four digits would be the sequence starting with 0001. So, the sequence would look something like this.
080001
080002
080003
Anyone do anything like this before?
--CREATE THE SEQUENCE FOR THE PRIMARY KEY
CREATE SEQUENCE [SCHEMA].[PK]_SEQ
START WITH 1
INCREMENT BY 1
MINVALUE 1
NOCACHE
NOCYCLE
ORDER;
The challenge is to create a sequence using the current year in the following format: FY9999
Where FY = "fiscal year", in this case it would be 08. Next year it would be 09. Then the next four digits would be the sequence starting with 0001. So, the sequence would look something like this.
080001
080002
080003
Anyone do anything like this before?