Error creating this procedure in Oracle 8

Discussion of open issues, suggestions and bugs regarding ODAC (Oracle Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
tat_nd
Posts: 1
Joined: Mon 03 Jul 2006 17:32

Error creating this procedure in Oracle 8

Post by tat_nd » Mon 03 Jul 2006 17:38

Hi, I´m new member in this forum. Can you help me?
I got this error when I execute the procedure in Oracle 8.
Really tks...

CREATE OR REPLACE PROCEDURE "P_BAG_BUSCALOJAS"
(p_id in NUMBER,
p_TpOcor in varchar2,
p_Cursor out TYPES.cursorType)
is
begin

if p_TpOcor is not null then

OPEN p_Cursor FOR

SELECT ID,NOME,EMAIL,ENDERECO,NUMERO,COMPLEMENTO,BAIRRO,CIDADE,TIPO,
ENDERECO || ', ' || NUMERO END,
DECODE (TIPO,1,'EMPRESA REPARADORA',2,'PONTO DE COLETA',3,'EMPRESA DE
HANDLING') NMTIPO
FROM BAG_LOJASCONVENIADAS
WHERE TIPO in (1,2)
ORDER BY TIPO,NOME;

else

OPEN p_Cursor FOR

SELECT ID,NOME,EMAIL,ENDERECO,NUMERO,COMPLEMENTO,BAIRRO,CIDADE,TIPO,
DECODE (TIPO,1,'EMPRESA REPARADORA',2,'PONTO DE COLETA',3,'EMPRESA DE
HANDLING') NMTIPO
FROM BAG_LOJASCONVENIADAS
WHERE TIPO = p_id
ORDER BY TIPO,NOME;


end if;

END P_BAG_BUSCALOJAS;


Regards,

Tat

Challenger
Devart Team
Posts: 925
Joined: Thu 17 Nov 2005 10:53

Post by Challenger » Wed 05 Jul 2006 08:57

Please describe the problem more detailed.

Post Reply