
31/07/2009, 10:49
|
 | | | Fecha de Ingreso: noviembre-2005
Mensajes: 331
Antigüedad: 19 años, 3 meses Puntos: 8 | |
Respuesta: recuperar Metadatos con cunsulta Amplio la informacion.
Ya tengo este quiery que filtra las tablas que contienen la columna mes. ahora solo agregar una condicion para que recupero solo aquellas en que el mes sea igual a 12.
SELECT information_schema.tables.table_name
FROM information_schema.tables INNER JOIN
information_schema.columns ON
information_schema.tables.table_name = information_schema.columns.table_name
WHERE (information_schema.tables.table_name NOT LIKE 'sys%')
AND (information_schema.tables.table_name <> 'dtproperties')
--AND (information_schema.tables.table_name not like 'vie%')
AND (information_schema.tables.table_schema <> 'INFORMATION_SCHEMA')
AND (information_schema.columns.column_name LIKE '%mes%')
AND (information_schema.tables.table_name not like 'VX%')
AND (information_schema.tables.table_name not like 'XX%')
AND (information_schema.tables.table_name not like 'zz%')
ORDER BY information_schema.tables.table_name, information_schema.columns.table_name |