Ver Mensaje Individual
  #7 (permalink)  
Antiguo 13/03/2015, 14:12
Avatar de Libras
Libras
Colaborador
 
Fecha de Ingreso: agosto-2006
Ubicación: En la hermosa perla de occidente
Mensajes: 7.412
Antigüedad: 17 años, 8 meses
Puntos: 774
Respuesta: Fusionar dos Tablas

Código SQL:
Ver original
  1. INSERT INTO clientes2
  2. SELECT t1.id FROM clientes AS t1
  3. LEFT JOIN clientes2 AS t2 ON (t1.id=t2.id)
  4. WHERE t2.clientes IS NULL
  5.  
  6.  
  7.  
  8. INSERT INTO clientes2
  9. SELECT t2.id FROM clientes AS t1
  10. LEFT JOIN clientes2 AS t2 ON (t1.id=t2.id)
  11. WHERE t2.clientes IS NOT NULL
__________________
What does an execution plan say to t-sql query? Go f**k yourself, if you are not happy with me