PL/SQL allocates memory for the variable's at runtime or at
compile time
Answer Posted / gaurav
For a CHAR variable, PL/SQL allocates at compile time enough memory for the maximum size.
For a VARCHAR2 variable, memory allocation depends on maximum size:
If the maximum size is less than 4,000 bytes, PL/SQL allocates at compile time enough memory for the maximum size.
If the maximum size is 4,000 bytes or more, PL/SQL allocates at run time enough memory for the actual value.
Thus, PL/SQL optimizes smaller VARCHAR2 variables for performance and larger ones for efficient memory use. ( from oracle doc)
| Is This Answer Correct ? | 4 Yes | 0 No |
Post New Answer View All Answers
How do I remove all records from a table?
What is oracle pl sql developer?
Can function return multiple values in sql?
What are triggers and its uses?
How to disable a trigger name update_salary?
what are the different type of sql's statements ? : Sql dba
1. is it possible to use the cursor atttibutes (%found ,% rowcount , %isopen , %notfound ) to our user defined cursor names ....... cursor cursor_name is select * from scott.emp if you use... cursor_name%found , %rowcount ,%isopen,%notfound...will it work... -------------------------- 2.what is the difference between the varray and index by table .. -------- 3. type type_name is table of number(8,3) index by binary_integer; identifier_name type_name; first , last , prior , next ,trim are the methods we can use it for the above type...simillary is there any way to apply for cursors... with thanks and regards..sarao...
Can we use views in stored procedure?
What are the different types of sql commands?
What are the indexing methods?
Is sql the best database?
What is the use of sqlerrd 3?
What is Difference Between Unique and Primary Key Constraints?
Which one is better sql or oracle?
Can we change the table name in sql?