mysql>
mysql> CREATE OR REPLACE VIEW VIEWS
-> (VIEW_CREATOR, VIEW_NAME, CREATE_TIMESTAMP,
-> WITHCHECKOPT, IS_UPDATABLE, VIEWFORMULA, COMMENT) AS
-> SELECT UPPER(V.TABLE_SCHEMA), UPPER(V.TABLE_NAME),
-> T.CREATE_TIME,
-> CASE
-> WHEN V.CHECK_OPTION = 'None' THEN 'NO'
-> WHEN V.CHECK_OPTION = 'Cascaded' THEN 'CASCADED'
-> WHEN V.CHECK_OPTION = 'Local' THEN 'LOCAL'
-> ELSE 'Yes'
-> END, V.IS_UPDATABLE, V.VIEW_DEFINITION, T.TABLE_COMMENT
-> FROM INFORMATION_SCHEMA.VIEWS AS V,
-> INFORMATION_SCHEMA.TABLES AS T
-> WHERE V.TABLE_NAME = T.TABLE_NAME
-> AND V.TABLE_SCHEMA = T.TABLE_SCHEMA
-> ;
Query OK, 0 rows affected (0.00 sec)