Ver Mensaje Individual
  #5 (permalink)  
Antiguo 22/12/2009, 08:08
Avatar de 8vio
8vio
 
Fecha de Ingreso: marzo-2008
Ubicación: Detras del monitor
Mensajes: 168
Antigüedad: 16 años, 1 mes
Puntos: 6
Respuesta: case anidados

CASE variable1
WHEN NULL THEN
CASE variable2
WHEN NOT NULL THEN
instruccion1;
ELSE
NULL;

END CASE;
ELSE
CASE variable2
WHEN NULL THEN
instruccion2;
ELSE
NULL;
END CASE;
END CASE;

En donde dice WHEN NOT NULL, coloca WHEN NULL THEN y haces la instruccion NULL que tienes en el else y en el else haces la instruccion1 y asi funciona.

Saludos.