Wednesday, 17 October 2012

How To Drop an Existing View in MySQL? | MySQL Interview Questions

If you have an existing view, and you dont want it anymore, you can delete it by using the “DROP VIEW viewName” statement as shown in the following script:
mysql> DROP VIEW faqComment;
Query OK, 0 rows affected (0.00 sec)
mysql> SELECT * FROM faqComment;
ERROR 1146 (42502): Table ggI.faqcomment doesn’t exist

No comments: