开发者

MySQL, Are views global or per session/connection?

I'm thinking of creating a VIEW to speed up things and my question is: Are VIEWS per session/connection or global?

Example:

User Foo is开发者_运维问答sues 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.

Now, does user Foo and user Bar work with the same VIEW X or do they have "private" VIEW X each?


They're created in the database and are not session bound. If the view actually is the same for the different sessions, you can just use CREATE OR REPLACE VIEW I think.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜