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

Home -> Community -> Usenet -> c.d.o.misc -> Re: SQL help

Re: SQL help

From: Eugene Gardner <Gene_at_VaxMan.prestel.co.uk>
Date: Thu, 07 Jan 1999 18:12:58 GMT
Message-ID: <3694e38a.27689669@news.prestel.co.uk>


Sounds like you need a PL/SQL block which reads the column in table A into an array and then uses the SUBSTR function to return the compunent you are interested in. A user defined function may be appropriate here.

Eugene.



"Martin Lynch" <mlynch_at_bfsec.bt.co.uk> wrote:

> Hi
>
> Im fairly new to oracle and ive been asked to do something like this.
>
> Define a table (table A) which has one column, but this column contains 1 or
> more fields concatenated.
>
> Then define another table (table B) which describes the first table in terms
> of field length and type etc.
>
> EG TABLE A
> row1 1234567890 (10 chars in the column)
>
> TABLE B
> row1 field 1 length 4
> row2 field 2 length 6
>
>
> A program would then be written which would look at table B and get the data
> definations in it and use this to manipulate the data in table A and display
> it in thenecessary form. Something like this
>
> OUTPUT
> part number 1234
> amount available 67890
>
> It is this program i need help with. Hope some one can help
>
> marty
>
>

Eugene Gardner.
Oracle Certified dba available for hire on NT or VMS platforms. Received on Thu Jan 07 1999 - 12:12:58 CST

Original text of this message

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