Re: PADDING IDENTITY COLUMNS/SEQUENCE NUMBERS with ZEROES

Re: PADDING IDENTITY COLUMNS/SEQUENCE NUMBERS with ZEROES

 

  


u can create a sequence till max 999
and while fetching
col test form 000
select my_sequence.nextval test from dual;

Deepa Kale -DBA
Jyoti Structures - Nasik(IT)



"Edwin Uy "
<oracledba-ezmlmshield-x17102285.[Email Address Removed] To: "LazyDBA Discussion" <[Email address protected]
azyDBA.com> cc:
Subject: PADDING IDENTITY COLUMNS/SEQUENCE NUMBERS with
04-08-2004 04:18 PM ZEROES





Hi all,

Is this at all possible or is this a stupid requirement? A customer
wants to have a column that is to auto-generated, that is, DBAs call
them IDENTITY in MSSQL and SEQUENCE in Oracle or DB2 I guess? Well, the
easy part is you can auto-generate the values, but customer wants them
3-char long, that is, 001, 002. Is it possible to achieve this or do I
just format the values as they are displayed on the FORM or as they are
extracted from SQL. Wait a minute, did I just answer my own question
there?

Cheers,


EDWIN ONG UY
\\|//
(o o)
^"^"^"^"^"^oOOo"^(_)^"oOOo^"^"^"^"^"^"^"^"^"^"^

"Choose a job you love, and you will never have to work a day in your
life." --Confucius
"How do I work? I grope." -- Albert Einstein
"Experience is the best teacher, enrolling in the class is the biggest
problem." -- Anonymous



--------
website: http://www.LazyDBA.com
Please don't reply to RTFM questions
Oracle documentation is here: http://tahiti.oracle.com
To unsubscribe: see http://www.lazydba.com/unsubscribe.html
To subscribe: see http://www.lazydba.com
By using this list you agree to these terms:
http://www.lazydba.com/legal.html






Oracle LazyDBA home page