Base de datos (MySQL)Generandoscript de consultas y subconsultas 
Consultas multitablaUnión Composición
UNIONSELECT nombreFROM tacategoria UNION SELECT marcaFROM taarticuloSELECT nombre FROM tacategoriaUNION ALL SELECT marca FROM taarticulo
Composición (CROSS JOIN - WHERE) SELECT * FROM tacategoriaCROSS JOIN taarticuloSELECT * FROM tacategoria, taarticulo
Composición (CROSS JOIN) SELECT tacategoria.Nombre, Marca FROM tacategoria, taarticuloSELECT tacategoria.CodCategoria, tacategoria.Nombre, Marca FROM tacategoria, taarticulo
Composición (INNER JOIN - ON) SELECT * FROM tacategoriaINNER JOIN taarticulo
INSelect nombre FROM tacategoria where CodCategoria In (Select CodCategoria FROM taarticulo Where Precio < 200)
CREACION DE VISTA CREATE VIEW resumen AS SELECT Marca, Nombre, Imagen FROM taarticulo

Gbd11