Well, there IS an ANSI standard called the INFORMATION_SCHEMA. Many vendors including Microsoft (SQL Server), Oracle, MySQL, Postgres support it, so that might be a first step.
For more information see this article here.
As for views, there's three INFORMATION_SCHEMA views for those:
- INFORMATION_SCHEMA.VIEWS
- INFORMATION_SCHEMA.VIEW_COLUMN_USAGE
- INFORMATION_SCHEMA.VIEW_TABLE_USAGE
There is a column called "VIEW_DEFINITION" in the "INFORMATION_SCHEMA.VIEWS" view, so that would probably give you the information you need in a somewhat stadandized way.
Marc