Home » SQL & PL/SQL » SQL & PL/SQL » Sequence
Sequence [message #190018] Tue, 29 August 2006 01:14 Go to next message
sam4all
Messages: 29
Registered: August 2006
Location: Bangalore
Junior Member
Hi

Normally we create sequence for numbers mainly for
creating Primary key .But i want to create sequence which
contain letters such as AA,BB,CC... or mixed A1210...,B1000
regards,

sam
Re: Sequence [message #190055 is a reply to message #190018] Tue, 29 August 2006 02:59 Go to previous message
JRowbottom
Messages: 5933
Registered: June 2006
Location: Sunny North Yorkshire, ho...
Senior Member
Why?
Unless you are planning to have meanningful information in your PKs (bad idea) then what advantage do you gain with your solution?

If you insist on doing it that way, you'll need to create a function that will get the value from the sequence, add whatever alphanumeric chrs you need, and return that value.
Previous Topic: Index
Next Topic: How to detect if a field is empty?
Goto Forum:
  


Current Time: Tue Dec 06 16:28:05 CST 2016

Total time taken to generate the page: 0.13587 seconds