declare type MyRecord is record (test2_str varchar (20), test2_id number); beginfor MyRecord in (. select t * from test2 t) loop update test2 t set t.test2_str = MyRecord.test2_id where t.test2_id = MyRecord.test2_id; end LOOP;
This declares a more composite specification.
This is a line in MyRecord, so I can take the test2_id of Test2.