On Wed, 11 Jan 2012, Brent Hilpert wrote:
On 2012 Jan 11, at 7:04 PM, Gene Buckle wrote:
On Wed, 11 Jan 2012, Brent Hilpert wrote:
The BASIC on the Microdata-REALITY system had
many of these improvements
back in the mid-70's, on a professional/business/mini-computer platform:
structured if-then-else, statement numbers are optional, indentable, etc.
Below is a code snippet from a program I wrote in 1977/8 (the numbers on
the far left are line numbers, not part of the source).
Known as Pick BASIC or DataBASIC.
70 IF
EXTRACT(FA,2,LC(NP),LC(P)+1)=1 THEN M=M+1;
DA=INSERT(DA,M,0,0EXTRACT(FA,NP,LC(2),1))
I've not seen this notation used (well recently) is the EXTRACT above
equivalent to: IF FA<2,LC(NP),LC(P)+1> THEN.... ?
Well, I couldn't really say .. 1978 was about the last time I used the
Microdata/Pick system.
IIRC, EXTRACT() was used to access the fields in a record, the record perhaps
having been READ() from the database; I don't recall the exact semantics.
Would it make sense if it were something like:
value = EXTRACT( record, index1, index2, index3 )
I never saw the x<a,b,c> notation .. syntactic shorthand introduced later?
It's manipulating a dynamic array - x<attribute, value, sub-value>. This
is how Pick (and Pick-alikes like REALITY, UniVerse, etc) store data.
If you have a record that looks like this:
001: NAME
002: ADDRESS
003: CITY]STATE]ZIP
You could work with it like this:
read workrec from customer.file, "1001" then
cust.name = workrec<1>
cust.addr = workrec<2>
cust.city = workrec<3,1>
cust.st = workrec<3,2>
cust.zip = workrec<3,3>
end
Pick has its quirks like any other DB system, but it stomps the guts out
of SQL on pure flexibility alone.
g.
--
Proud owner of F-15C 80-0007
http://www.f15sim.com - The only one of its kind.
http://www.diy-cockpits.org/coll - Go Collimated or Go Home.
Some people collect things for a hobby. Geeks collect hobbies.
ScarletDME - The red hot Data Management Environment
A Multi-Value database for the masses, not the classes.
http://www.scarletdme.org - Get it _today_!
Political correctness is a doctrine, fostered by a delusional, illogical
minority, and rabidly promoted by an unscrupulous mainstream media, which
holds forth the proposition that it is entirely possible to pick up a turd
by the clean end.