开始
SET SERVEROUTPUT ON; DECLARE TYPE emp_record_type IS RECORD ( empno emp.empno%TYPE, empname emp.ename%TYPE); emp_record emp_record_type; BEGIN emp_record.empno:=10; emp_record.empname:='TEST'; dbms_output.put_line('empno: '||emp_record.empno ||' empname: ' || emp_record.empname); END; /
运行结果:
anonymous block completed empno: 10 empname: TEST
结束
本文转自健哥的数据花园博客园博客,原文链接:http://www.cnblogs.com/gaojian/archive/2012/11/14/2769458.html,如需转载请自行联系原作者