COBOL

COBOL (/ˈkoʊbɒl/) is a compiled computer programming language designed for business use. It is imperative, procedural and, since 2002, object-oriented. It was designed in 1959 by the Conference on Data Systems Languages (CODASYL) and was largely based on previous programming language design work by Grace Hopper, commonly referred to as “the mother of COBOL”. COBOL stands for COmmon Business-Oriented Language.

COBOL is primarily used in business, finance, and administrative systems for companies and governments. In 1997, Gartner Group estimated that there were a total of 200 billion lines of COBOL in existence which ran 80% of all business programs.

COBOL was one of the first programming languages to be standardised: the first COBOL standard was issued by ANSI in 1968. The standard has been revised four times since then, with ISO publishing the latest standard as ISO/IEC 1989:2014.

Background

Computer users and manufacturers were becoming concerned about the rising cost of programming. A 1959 survey had found that in any data processing installation, programming cost at least $800,000 and that translating programs to run on new hardware would cost $600,000. In a time where new programming languages were proliferating at an ever increasing rate, the same survey suggested that if a common business-oriented language were used, conversion would be far cheaper and faster.

In April 1959, representatives from academia, computer users and manufacturers met at the University of Pennsylvania to organise a formal meeting on common business languages. Representatives included Grace Hopper, inventor of the English-like data processing language FLOW-MATIC, Jean Sammet and Saul Gorn.

The group asked the Department of Defense (DoD) to sponsor an effort to create a common business language. The delegation impressed Charles A. Phillips, director of the Data System Research Staff at the DoD, who thought that they “thoroughly understood” the DoD’s problems. The DoD operated 225 computers, had a further 175 on order and had spent over $200 million on implementing programs to run on them. Portable programs would save time, reduce costs and ease modernisation.

Phillips agreed to sponsor the meeting and tasked the delegation with drafting the agenda.

Legacy

COBOL programs are used globally in governments and businesses, and are running on diverse operating systems such as z/OS, VME, Unix and Windows. In 1997, the Gartner Group reported that 80% of the world’s business ran on COBOL with over 200 billion lines of code and 5 billion lines more being written annually.

Near the end of the twentieth century, the year 2000 problem (Y2K) was the focus of significant COBOL programming effort, sometimes by the same programmers who had designed the systems decades before. The particular level of effort required to fix COBOL code has been attributed[by whom?] to the large amount of business-oriented COBOL, as business applications use dates heavily, and to fixed-length data fields. After the clean-up effort put into these programs for Y2K, a 2003 survey found that many remained in use. The authors said that the survey data suggest “a gradual decline in the importance of Cobol in application development over the [following] 10 years unless … integration with other languages and technologies can be adopted”.

In 2006 and 2012, Computerworld surveys found that over 60% of organisations used COBOL (more than C++ and Visual Basic .NET) and that for half of those, COBOL was used for the majority of their internal software. 36% of managers said they planned to migrate from COBOL and 25% said they would like to if it was cheaper. Instead, some businesses have migrated their systems from expensive mainframes to cheaper, more modern systems, while maintaining their COBOL programs.

Syntax

COBOL has an English-like syntax which is used to describe nearly everything in a program. For example, a condition can be expressed as x IS GREATER THAN y or more concisely as x GREATER y or x > y. More complex conditions can be “abbreviated” by removing repeated conditions and variables. For example, a > b AND a > c OR a = d can be shortened to a > b AND c OR = d. As a consequence of this English-like syntax, COBOL has over 300 keywords.[89]

However, compiler extensions allow many implementations to have far more: one implementation recognizes over 1,100 keywords.[90] Some of the keywords are simple alternative or pluralized spellings of the same word, which provides for more English-like statements and clauses; e.g., the IN and OF keywords can be used interchangeably, as can IS and ARE, and VALUE and VALUES.

The syntactical elements of a COBOL program are “words”, “literals”, and “punctuation”. Word elements include reserved keywords, user-defined identifiers, and labels, and must be separated from other words by spaces, newlines, or punctuation elements. Identifiers (for data items and files, as well as paragraph and section labels) are case-insensitive and may contain dashes for readability, and can be up to 30 characters long. Literal elements include numeric constants and quoted character (string) constants.

A COBOL program is split into four divisions: the identification division, the environment division, the data division and the procedure division. The identification division specifies the name and type of the source element and is where classes and interfaces are specified. The environment division specifies any program features that depend on the system running it, such as files and character sets. The data division is used to declare variables and parameters. The procedure division contains the program’s statements. Each division is sub-divided into sections which are made up of paragraphs.

From Wikipedia, the free encyclopedia.

Read more: en.wikipedia.org/wiki/COBOL

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>