I guess the shortcoming is that you can’t do some subquery in the select part, hypothetical syntax:
select ( select col_name from meta_info_about_MYTABLE where col_name not in ('nope', 'nada') ) from MYTABLE;
but maybe there could be a hack to get the column names as rows and work from that…
You can, through the system catalog. Then you could query this and omit the named tables, producing a new query string which can be executed. Unfortunately, I think you need to use a stored procedure to do this (via EXECUTE)
Wow, the hack is pretty neat. This bash+perl script is a bit intimidating, though :)
This is great, love stuff like this.
I guess the shortcoming is that you can’t do some subquery in the select part, hypothetical syntax:
but maybe there could be a hack to get the column names as rows and work from that…
You can, through the system catalog. Then you could query this and omit the named tables, producing a new query string which can be executed. Unfortunately, I think you need to use a stored procedure to do this (via EXECUTE)
Wow, the hack is pretty neat. This bash+perl script is a bit intimidating, though :)
This is great, love stuff like this.