刚看了下物化视图,有个问题一直想不明白。想问下各位。
创建完物化视图。比如A表的物化视图create MATERIALIZED VIEW test_view on A as select * from A where type = 1;在查询时也是select * from test_view.像这样的,和直接查询表Aselect * from a where type = 1有什么区别?
速度会快?能否详细解释一下
创建完物化视图。比如A表的物化视图create MATERIALIZED VIEW test_view on A as select * from A where type = 1;在查询时也是select * from test_view.像这样的,和直接查询表Aselect * from a where type = 1有什么区别?
速度会快?能否详细解释一下
create MATERIALIZED VIEW test_view on A as select * from A where type = 1;-----这个直接是一个结果集,不经过TYPE=1的查询
接着上面的
create MATERIALIZED VIEW test_view on A as select * from A where type = 1直接sqlselect * from A where type =1 and moto = 123和select * from test_view where moto = 123也是物化视图快?何谓一般来说。貌似物化视图创建以后多了一个名称 是视图名字的表
create MATERIALIZED VIEW test_view on A as select * from A where type = 1直接sqlselect * from A where type =1 and moto = 123和select * from test_view where moto = 123也是物化视图快?貌似物化视图创建以后多了一个名称 是视图名字的表
你上面的就一个表,对比起来没有意思的。
物化视图~~~符合一定条件的数据快照个人理解。结贴了。有什么不对的,大家指正。谢谢