Array
(
)

Converte Stored Procedure do FireBird para o SQL Server

Stci
   - 09 set 2003

Oi Pessoal, alguém pode me ajudar a converte esta procedure do FireBird para o SQl Server.

Obrigado

-----
CREATE PROCEDURE PS_PNEUS
RETURNS (
NPNEU VARCHAR(10) CHARACTER SET NONE,
MARCA VARCHAR(13) CHARACTER SET NONE,
TIPO VARCHAR(19) CHARACTER SET NONE,
DIMENSAO VARCHAR(19) CHARACTER SET NONE,
NLONAS VARCHAR(3) CHARACTER SET NONE,
SIT VARCHAR(3) CHARACTER SET NONE,
STATUS VARCHAR(16) CHARACTER SET NONE,
NSERIE VARCHAR(17) CHARACTER SET NONE,
DOT VARCHAR(7) CHARACTER SET NONE,
NFROTA VARCHAR(10) CHARACTER SET NONE,
PRODA VARCHAR(5) CHARACTER SET NONE,
CECU_ID FLOAT,
CECU_CODIGO VARCHAR(10) CHARACTER SET NONE,
CECU_DESCRICAO VARCHAR(36) CHARACTER SET NONE)
AS
BEGIN
FOR
SELECT PNEUS.NPNEU, PNEUS.MARCA, PNEUS.TIPO, PNEUS.DIMENSAO, PNEUS.NLONAS, PNEUS.SIT, PNEUS.STATUS, PNEUS.NSERIE, PNEUS.DOT, PNEUS.NFROTA, PNEUS.PRODA, PNEUS.CECU_ID, TCCUSTOS.CECU_CODIGO, TCCUSTOS.CECU_DESCRICAO
FROM PNEUS
INNER JOIN TCCUSTOS ON (PNEUS.CECU_ID = TCCUSTOS.CECU_ID)
INTO :NPNEU,
:MARCA,
:TIPO,
:DIMENSAO,
:NLONAS,
:SIT,
:STATUS,
:NSERIE,
:DOT,
:NFROTA,
:PRODA,
:CECU_ID,
:CECU_CODIGO,
:CECU_DESCRICAO
DO
BEGIN
IF (STATUS IS NULL) THEN
STATUS = ´´
;
IF (STATUS = ´E´) THEN
STATUS = ´Estoque´
;
IF (STATUS = ´U´) THEN
STATUS = ´Usado´
;
IF (STATUS = ´R´) THEN
STATUS = ´Reformado´
;
SUSPEND;
END
END
-----