Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: update statement

Re: update statement

From: Mark D Powell <mark.powellNOmaSPAM_at_eds.com.invalid>
Date: 2000/08/04
Message-ID: <057cd9d8.fc159a6e@usw-ex0102-015.remarq.com>#1/1

analyst_user_at_my-deja.com wrote:
>I have two tables that look like the following.
>
>CODE_TABLE
>CODE SYMBOL
>12 T,W,R
>11 W,Q
>10 E
>
>SYMBOL_XREF
>OLD_SYMBOL NEW_SYMBOL
>T TX
>W WY
>R RV
>Q QU
>E EP
>
>
>I want to update the CODE_TABLE with the new symbols from the
>SYMBOL_XREF table.
>
>The problem is that the SYMBOL field of the CODE_TABLE is comma
>delimited with multiple values.
>
>Any help would be greatly appreciated.
>

If this was my task I would use pl/sql. You can use the instr function to determine if comma's are present and in what location. By starting at the rear of the field you can extract a value by using substr of the data starting at the comma position + 1 for a lenth of the column length - 1 - comma position. You then reset your working length variable to the position.

Got questions? Get answers over the phone at Keen.com. Up to 100 minutes free!
http://www.keen.com Received on Fri Aug 04 2000 - 00:00:00 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US