Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Looping
Mark D Powell wrote:
> On Feb 4, 10:47 pm, DPDesroc..._at_gmail.com wrote:
>> I have an SQL questions. >> I am trying to reset about 28 sequence generators with a looping >> program; my problem comes when I try to trim the prefix and suffix >> from the max number in the database. >> >> Currently I am using a left and right trim as follows. XXX = column >> name in this example I do know from looking at another table that >> controls the prefix and suffix that all prefix and suffix are alpha. >> RTRIM(ltrim(max(XXX),'ABCDEFGHIJKLMNOPQRSTUVWXYZ'),'ABCDEFGHIJKLMNOPQRSTUVWXYZ') >> >> any help would be great.
Also use TRIM rather than LTRIM(RTRIM( when you need "trim" functionality.
-- Daniel A. Morgan University of Washington damorgan_at_x.washington.edu (replace x with u to respond) Puget Sound Oracle Users Group www.psoug.orgReceived on Mon Feb 05 2007 - 12:01:07 CST
![]() |
![]() |