Código SQL [-] select codigo, cantidad1, fecha where clave = 2 union select codigo, cantidad2, fecha where clave <> 2
select codigo, cantidad1, fecha where clave = 2 union select codigo, cantidad2, fecha where clave <> 2