What are % TYPE and % ROWTYPE ? What are the advantages of
using these over datatypes?
Answers were Sorted based on User's Feedback
Answer / swapna
"% Type "is used to extract definition of the column of a
table.
"%Rowtype" is used to extract definition of the columns of
all columns.
| Is This Answer Correct ? | 6 Yes | 1 No |
Answer / nakul.v
%TYPE provides the data type of a variable or a database
column to that variable.
%ROWTYPE provides the record type that represents a entire
row of a table or view or columns selected in the cursor.
The advantages are :
I. Need not know about variable's data type.
II.If the database definition of a column in a table
changes, the data type of a variable changes accordingly.
| Is This Answer Correct ? | 4 Yes | 0 No |
Answer / nishi
%TYPE provides the data type of a variable or a database column to that variable.
%ROWTYPE provides the record type that represents a entire row of a table or view or columns selected in the cursor.
The advantages are :
I. Need not know about variable's data type.
II.If the database definition of a column in a table changes, the data type of a variable changes accordingly.
| Is This Answer Correct ? | 1 Yes | 0 No |
Answer / manoj
"%Type" :-It reffer one datatype which take
data type of a column in table,
Previously defined variable(Anchor type)
"%Rowtype" :-Have all type Refered May be for
Table,
Cursor,
Ref Cursor,
curor variable etc.
| Is This Answer Correct ? | 1 Yes | 2 No |
What is the difference between inner join and natural join?
what is the purpose of update command in oracle?
What is database white box testing and black box testing?
What is information schema in sql?
What is difference between cursor and trigger?
What are the datatypes available in pl/sql ?
Explain what is sql?
Does inner join remove duplicates?
How delete all records from table in sql?
What is a pragma statement?
What are inner outer left and right joins in sql?
Is sql between inclusive?
Oracle (3259)
SQL Server (4518)
MS Access (429)
MySQL (1402)
Postgre (483)
Sybase (267)
DB Architecture (141)
DB Administration (291)
DB Development (113)
SQL PLSQL (3330)
MongoDB (502)
IBM Informix (50)
Neo4j (82)
InfluxDB (0)
Apache CouchDB (44)
Firebird (5)
Database Management (1411)
Databases AllOther (288)