Re: UPDATE PROBLEM: PLS HELP!!!!!

From: Richard Frazier <rfrazier_at_mailstorm.dot.gov>
Date: 1995/11/02
Message-ID: <47atvj$ef1_at_news.dot.gov>#1/1


sl6gs_at_cc.usu.edu wrote:
: Hi Sirs:
 

: I have a oracle table PT_CODE with one column DIAG_CODE.
: with xxx.xxx(say '112.100') , I want to change DIAG_CODE
: to xxx.xxxxx('say ' 112.10000'). I already wrote a fucntion CODE
: using PL/SQL
: to do this change (say , CODE('112.100') ='112.10000') .
 

: but as there 60000 records in table PT_CODE, how to
: do this by writing a program using PL/SQL or just SQL.
 

: I could not figure out how to solve above problem,
: any hint form you will be greatly appreciated!!!

if you are simply trying to expand each record by adding 00 to the end then try this;

alter table pt_code modify (diag_code char(9)) or whatever the new size should be

update pt_code
set diag_code = diag_code||'00';

hope this helps, rick Received on Thu Nov 02 1995 - 00:00:00 CET

Original text of this message