Ensuring backward compatibility, PL-SQL Programming

Ensuring Backward Compatibility 

The PL/SQL Version 2 permits some abnormal behavior which Version 8 disallows.

Particularly, Version 2 permits you to

(i) Make the forward references to RECORD and TABLE types when declaring the variables.

(ii) Specify the name of the variable (not a datatype) in the RETURN clause of the function specification.

(iii) Assign values to the elements of an index-by table IN parameter.

(iv) Pass the fields of a record IN parameter to the other subprogram as OUT parameters

(v) Use the fields of a record OUT parameter on the right-hand side of the assignment statement.

(vi) Use the OUT parameters in the FROM list of a SELECT statement.

For backward compatibility, you might want to remain this particular Version 2 behavior. You can do it by setting the PLSQL_V2_COMPATIBILITY flag. At server side, you can set the flag in 2 ways:

(i) Add the line below to the Oracle initialization file:

PLSQL_V2_COMPATIBILITY=TRUE

(ii)Execute one of the SQL statements below:

ALTER SESSION SET PLSQL_V2_COMPATIBILITY = TRUE;

ALTER SYSTEM SET PLSQL_V2_COMPATIBILITY = TRUE;

Posted Date: 10/5/2012 5:02:58 AM | Location : United States







Related Discussions:- Ensuring backward compatibility, Assignment Help, Ask Question on Ensuring backward compatibility, Get Answer, Expert's Help, Ensuring backward compatibility Discussions

Write discussion on Ensuring backward compatibility
Your posts are moderated
Related Questions
Expressions   An expression is a randomly complex combination of the constants, variables, literals, operators, & function calls. The simplest expression is the single variabl

Using a join on 3 tables, select 5 columns and 10 rows from the 3 tables without the use of a Cartesian product Query: SELECT E.LAST_NAME, E.FIRST_NAME, S.BUILDING, S.BRAN

Write a cursor to open an employee database and fetch the employee record whose age is greater than 45

Parameter and Keyword Description: dynamic_string: This is a string variable, literal, or expression which represents a SQL statement or the PL/SQL block. define_vari

1.( /5 marks) Suppose that a B+-tree index with the search key (dept_name, building) is available on relation department. What would be the best way to handle the following selecti

Comparison Operators The Comparison operators can compare one expression to another. The outcome is always true, false, or null. Usually, you use a comparison operators in condi

Using raise_application_error The Package DBMS_STANDARD that is supplied with Oracle gives language facilities that help your application to interact with Oracle. For illustra

Example of Check Constraints Example: Workaround for when subqueries not permitted in CHECK constraints CREATE FUNCTION NO_MORE_THAN_20000_ENROLMENTS ( ) RETURNS BOOLEAN

Using Invoker Rights: By default, the stored procedure executes with the privileges of its definer, not its invoker. These procedures are bound to the schema in which they inh

DELETE Command - SQL Loosely speaking, DELETE removes some existing rows from its target table. Suppose the university decides that course C3 is to be withdrawn. Example shows