%TYPE and %ROWTYPE in oracle

Published on by LakshmiSaahul,Dhana Royal

%TYPE and %ROWTYPE

%TYPE is used to declare a variable that is of the same type as a specified table’s column.

Emp_number emp.empno%type;

%ROWTYPE is used to declare a record(variable that represents the entire row of a table).

Emp_record emp%rowtype

Declare table-based record for employee table.

emp_rec employee%ROWTYPE

Advertising
To be informed of the latest articles, subscribe:
Comment on this post