
14/03/2008, 06:08
|
Colaborador | | Fecha de Ingreso: marzo-2008 Ubicación: Sabadell
Mensajes: 4.897
Antigüedad: 16 años, 11 meses Puntos: 574 | |
Re: Consulta en multiples tablas fallida Que tal UNION ALL
Código:
SELECT "casa" as tipo, direccion
FROM casas
WHERE valor = 100000
UNION ALL
SELECT "departamento" as tipo, direccion
FROM departamentos
WHERE valor = 100000
UNION ALL
SELECT "terreno" as tipo, direccion
FROM terrenos
WHERE valor = 100000;
|