一个表分成多个水平视图,如
create view t1 as select col1,col2 from total where table='t1'
create view t2 as select col1,col2 from total where table='t2'
create view t3 as select col1,col2 from total where table='t3'
插入视图数据的时候因为table为null,故查不出,有没有办法是table列的列为插入视图的名字
大神们看看
http://blog.csdn.net/kk185800961/article/details/46482769
设计上应该反过来:t1
、t2
、t3
作为各自独立的表对象提供日常查询/编辑;然后创建一个 total
视图通过 UNION ALL
把这些表合并起来。
参考 使用分区视图.aspx)