Re: basic plsql question
From: Wario <r0cky_at_insightbb.com>
Date: 27 Aug 2004 11:06:59 -0700
Message-ID: <9204a53e.0408271006.5522fc5a_at_posting.google.com>
end loop;
Date: 27 Aug 2004 11:06:59 -0700
Message-ID: <9204a53e.0408271006.5522fc5a_at_posting.google.com>
This function will let you test the format any string up to 50 characters. You may modify is needed.
function word_format (word varchar2) return varchar2 is
fmt varchar2(50);
ltr char(1);
begin
for x in 1..length(word) loop
ltr := substr(word,x,1); fmt := fmt || case when ltr between 'A' and 'Z' then 'X' when ltr between 'a' and 'z' then 'X' when ltr between '0' and '9' then '9' else ltr end;
end loop;
return fmt;
end;
/
if word_format('A54698') = 'X99999' then
.....
end if;
Received on Fri Aug 27 2004 - 20:06:59 CEST