Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
This article describes why SQL Server Migration Assistant (SSMA) for Oracle doesn't convert the function call when number of parameters passed is less than the defined number of parameters.
Background
When calling functions in Oracle, you can pass parameters by using:
- Positional notation. Parameters are specified in the order in which they're declared in the procedure.
- Named notation. The name of each parameter is specified along with its value. An arrow (
=>
) serves as the association operator. The order of the parameters isn't significant. - Mixed notation. The first parameters are specified with positional notation, and then they're switched to named notation for the subsequent parameters.
Whenever parameter is omitted in a stand-alone function call, SSMA generates an error message.
Example
In the following example, you create a function and pass one default parameter in that function:
CREATE OR REPLACE FUNCTION MULTIPLICATION (
a int,
b int DEFAULT 1
)
RETURN NUMBER
AS
BEGIN
RETURN a*b;
END;
/
SELECT MULTIPLICATION(20) FROM DUAL;
When you try to convert the previous code in SSMA, it generates the following error message:
O2SS0104: Unpackaged function call is missing a parameter
Possible remedies
To resolve this error, you must ensure that the SSMA project settings are properly configured:
- Navigate to the Tools menu, and select Project Settings.
- Then, select the General tab.
- Under Statements Conversion, change Convert calls to subprograms that use default arguments to Yes.
Related conversion messages
- O2SS0102: Procedure (function) call is missing a parameter
- O2SS0105: Function (procedure) call is missing a parameter