Avatar of chalie001
chalie001
 asked on

format accontno

how can i format account no

select acctno from employee

bb0201938

display like
bb-010-1938

oracle database
Oracle DatabaseDatabases

Avatar of undefined
Last Comment
chalie001

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
Ryan Chong

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question
Ryan Chong

i assume you mean "bb-020-1938", NOT "bb-010-1938"

bb0201938 >> bb-020-1938
awking00

Will the acctno always be in the same format (e.g. in your example 2 alpha characters followed by 7 digits)?
chalie001

ASKER
it can be both

12-001-1451
bb-020-7775
All of life is about relationships, and EE has made a viirtual community a real community. It lifts everyone's boat
William Peck
slightwv (䄆 Netminder)

Did you try the substr in the first post?

If that didn't work, please explain why.
chalie001

ASKER
correct