8.4 中文镜像

MySQL 8.4 参考手册 · 中文镜像

正文为中文,英文原文默认隐藏。点击任意中文段落即可展开 / 收起对应英文原文。

打开官方英文原文 ↗

译文由机器翻译生成,仅供理解参考;有疑问请以官方英文原文为准。

中文点击中文段落可显示 / 隐藏英文原文本页译文覆盖 78%

A.6 MySQL 8.4 常见问题:视图A.6 MySQL 8.4 FAQ: Views

A.6.1. 我在哪里可以找到关于 MySQL 视图的文档? A.6.1. Where can I find documentation covering MySQL Views?
A.6.2. 有关 MySQL 视图的讨论论坛吗? A.6.2. Is there a discussion forum for MySQL Views?
A.6.3. 如果底层表被删除或重命名,视图会发生什么? A.6.3. What happens to a view if an underlying table is dropped or renamed?
A.6.4. MySQL 有表快照功能吗? A.6.4. Does MySQL have table snapshots?
A.6.5. MySQL 有物化视图吗? A.6.5. Does MySQL have materialized views?
A.6.6. 可以向基于联接的视图插入数据吗? A.6.6. Can you insert into views that are based on joins?

A.6.1.

我在哪里可以找到关于 MySQL 视图的文档?Where can I find documentation covering MySQL Views?

请参见 第 27.5 节,“使用视图”。See Section 27.5, “Using Views”.

您也可能会发现 MySQL 用户论坛 很有帮助。You may also find the MySQL User Forums to be helpful.

A.6.2.

有没有关于 MySQL 视图的讨论论坛?Is there a discussion forum for MySQL Views?

请参见 MySQL 用户论坛。See the MySQL User Forums.

A.6.3.

如果基础表被删除或重命名,视图会发生什么情况?What happens to a view if an underlying table is dropped or renamed?

在创建视图之后,可以删除或修改定义所引用的表或视图。要检查视图定义是否存在此类问题,请使用CHECK TABLE语句。(参见第 15.7.3.2 节,“CHECK TABLE 语句”。)After a view has been created, it is possible to drop or alter a table or view to which the definition refers. To check a view definition for problems of this kind, use the CHECK TABLE statement. (See Section 15.7.3.2, “CHECK TABLE Statement”.)

A.6.4.

MySQL 有表快照吗?Does MySQL have table snapshots?

没有。No.

A.6.5.

MySQL 有物化视图吗?Does MySQL have materialized views?

没有。No.

A.6.6.

可以向基于连接的视图插入数据吗?Can you insert into views that are based on joins?

这是可能的,前提是您的INSERT语句包含一个列列表,从而明确表示只涉及一个表。It is possible, provided that your INSERT statement has a column list that makes it clear there is only one table involved.

您不能在视图上使用单个插入操作插入到多个表。You cannot insert into multiple tables with a single insert on a view.