0

我正在考虑创建一个视图来加快速度,我的问题是:每个会话/连接的视图还是全局视图?

例子:

User Foo issues a query that creates a VIEW X, then user Foo continues to query
against VIEW X.  
Meanwhile, User Bar issues the same query that creates a VIEW X because the creation and the name is hard coded into the function issuing the query.

现在,用户 Foo 和用户 Bar 是否使用相同的 VIEW X 或者他们每个都有“私有”VIEW X?

4

1 回答 1

2

它们是在数据库中创建的,不受会话限制。如果不同会话的视图实际上是相同的,我认为您可以使用 CREATE OR REPLACE VIEW 。

于 2011-01-20T12:55:30.967 回答