Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Fortran ... Basic ... actually I'd have thought that zero was a
> minority position. Fashions change I guess.
When I started programming the top four languages for business
programming were COBOL, BASIC, RPG II, and assembly language.
(Pascal and C came later, and I never saw much use of Fortran by
anyone other than mathematicians.) Except for assembly language,
the subscripts for arrays either started with 1 always, or that was
the default. Given when it was first developed, it's not too
surprising that the SQL standard adopted 1 as the first element of
an array.
Which is more natural depends on whether you think of the subscript
in terms of ordinal positions or offsets from the base address.
--
Kevin Grittner
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company