Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: 9i R2 database vs. 9i R2 Forms Developer PL/SQL compatibility
Harald Maier <maierh_at_myself.com> wrote in message news:<m3wud8z0oh.fsf_at_ate.maierh>...
> > For associative array functionality (it's a documented feature in the 9i R2
> > PL/SQL reference) for key/value pairs:
> >
> > DECLARE
> > TYPE CUST_ID_TYPE IS TABLE OF NUMBER INDEX BY VARCHAR(30);
> > CUST_ID CUST_ID_TYPE;
> > ID NUMBER;
> > BEGIN
> > CUST_ID('FLINTSONE') := 1;
> > CUST_ID('RUBBLE') := 7;
> > ID := CUST_ID('FLINTSTONE');
> > ...
> > END;
>
> Especially, perl programer like this feature :).
> Harald
Associative arrays are also natively supported in Tcl (and therefore Expect), KornShell newer than 11/98 version, Python and Visual Basic (called dictionaries in both), Java (Hashtables). PL/SQL finally catches up with other languages in this functionality.
Yong Huang Received on Thu Aug 21 2003 - 10:52:20 CDT