In PL/SQL, a varray
can be initialised at creation time as:
TYPE colour_tab IS VARRAY(3) OF VARCHAR2(20);
french_colours colour_tab := colour_tab('RED','WHITE','BLUE');
Is there an equivalent method of initialisation for PL/SQL record types?
type location_record_type is record (
street_address varchar2(40),
postal_code varchar2(12),
city varchar2(30),
state_province varchar2(25),
country_id char(2) not null := 'US'
);
No, there is not. You have to assign each value explicitly. Documentation reference here.