Club Delphi  
    FTP   CCD     Buscar   Trucos   Trabajo   Foros

Retroceder   Foros Club Delphi > Bases de datos > Firebird e Interbase
Registrarse FAQ Miembros Calendario Guía de estilo Temas de Hoy

Respuesta
 
Herramientas Buscar en Tema Desplegado
  #1  
Antiguo 21-09-2005
jmlifi jmlifi is offline
Miembro
 
Registrado: abr 2005
Posts: 188
Poder: 20
jmlifi Va por buen camino
Error a la hora de generar un trigger

Trabajo con interbase 5, realizo la siguiente instruccion:

CREATE TRIGGER ACTPEDIDO1 FOR PZALB ACTIVE
AFTER INSERT POSITION 0
as
declare variable n int;
declare variable nPedido int;
begin
select Pedido
from Albaran
where N_Alb=new.N_Alb
into :nPedido;
select Realzdas from pzpedido
where (PzPedido.O_Ped = new.O_Ped) AND
(PzPedido.Pedido = :nPedido)
into :n;
if (n is null) then
n = 0;
if (not new.QA is null) then
n = n + new.QA;
update PzPedido set Realzdas = :n
where (PzPedido.O_Ped = new.O_Ped) AND
(PzPedido.Pedido = :nPedido);
end


Meda el error : XSQLDA index out of range.

¿Como lo soluciono?
Responder Con Cita
Respuesta



Normas de Publicación
no Puedes crear nuevos temas
no Puedes responder a temas
no Puedes adjuntar archivos
no Puedes editar tus mensajes

El código vB está habilitado
Las caritas están habilitado
Código [IMG] está habilitado
Código HTML está deshabilitado
Saltar a Foro


La franja horaria es GMT +2. Ahora son las 17:23:05.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Traducción al castellano por el equipo de moderadores del Club Delphi
Copyright 1996-2007 Club Delphi