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

Home -> Community -> Mailing Lists -> Oracle-L -> RE: Cobol redefine in SQL

RE: Cobol redefine in SQL

From: Carel-Jan <cjpengel.dbalert_at_xs4all.nl>
Date: Thu, 27 Nov 2003 11:44:27 -0800
Message-ID: <F001.005D8069.20031127114427@fatcity.com>


At 05:44 27-11-03 -0800, you wrote:
>I'm looking for a solution that is using only one table not multiple tables.
>In fact a dynamic column redefinition feature (cobol redefines) is what I
>need in Oracle SQL.
>
>Stephane

Hi Stephane,

Instead of flaming Cobol I'll try help you with a solution. Please download the utilities manual, as I advised last time, look at the SQL*Loader part and take case study 5. It will tell you exactly what you want. Redefines, Occurs, all is covered. I think this will solve your problem. You can have as many INTO TABLE clauses as you like, one for each redefine. Every INTO TABLE might refer to the same table. The WHEN clause helps you to determine what INTO TABLE clause to use.

To the others in this thread, IMHO Cobol might not be state of the art, whithout it IT might not have been what it is now. I hate the language, actually never ever wrote a working program in it due to some mental blocks connected with the syntax, but I've done many data-conversions of files, based on the record-layouts. Redefines might be ugly, for those of you who do not remember the amazing discovery of a 5 MB (spelled MegaByte) harddisk, and spending 3 hours discussing with 4 programmers how to use this amazing amount of diskspace in a usefull way some hsitorical awareness might help. Cobol, coming from the early sixties AFAIK, doesn't support null-values. Actually, when they started using it, there were no disks at all. Costs of storage were sky-high, and every byte saved was welcome. So, redefines, and repeating groups (OCCURS 10 TIMES in a field definition) really helped people writing usefull programs, based on serial access to data stored on ticker tapes and magnetic tapes. It is about time to get some awareness of the history of our trade, before it all fades away.

Visit Miracle's Oracle museum, running Oracle V5 on a 286 / Dos 6.0 system, or similar old-fashioned. Do you condemn the T-Ford as well? That doesn't meet today's standards, but was most important to the development of a certain country in this world.

Regards, Carel-Jan

-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Carel-Jan
  INET: cjpengel.dbalert_at_xs4all.nl

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
Received on Thu Nov 27 2003 - 13:44:27 CST

Original text of this message

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