performance - View over several databases, how to improve speed ? -
i have 3 databases, in each database 2 tables, make interface users easier have created view on these 6 tables , added database , table column in view user can still filter if he/she wants data. feel performance not be. feel though clause defines example data db1 not necessary view fetches data first , performs filtering. how can make view smart enough avoid getting data db1 in frist place in such situation ?
what want partitioned view.
you create these specifying constraints each of tables in view, sql server know information there without having fetch it:
i.e.
-- on server1: create table customers_33 (customerid integer primary key check (customerid between 1 , 32999), ... -- additional column definitions) -- on server2: create table customers_66 (customerid integer primary key check (customerid between 33000 , 65999), ... -- additional column definitions) -- on server3: create table customers_99 (customerid integer primary key check (customerid between 66000 , 99999), ... -- additional column definitions) full explanation here: http://msdn.microsoft.com/en-us/library/aa933141(v=sql.80).aspx
Comments
Post a Comment