1
When trying to compile the following Function:
CREATE OR REPLACE FUNCTION f_id_fornecedor(Nomefornecedor in varchar(50))
RETURN integer IS
codigoforncedor integer;
BEGIN
SELECT codfornecedor INTO codigofornecedor FROM TBFORNECEDOR WHERE NOFORNECEDOR=Nomefornecedor;
IF codigofornecedor <> NULL THEN
RETURN codigofornecedor;
ELSE Raise_Application_Error(-20004,
'Fornecedor não existe: ' || nomefornecedor);
END IF;
END;
get the following error:
PLS-00103: Encountered the Symbol "(" when expecting one of the following:
:= . ) , @ % default Character The Symbol ":=" was substituted for "("to continue.
Compile error at line 1, column 53 PLS-00103: Encountered the Symbol "end-of-file" when expecting one of the following:
; The Symbol ";" was substituted for "end-of-file" to continue.
Compile error at line 12, column 21