Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/sql-server/25.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/database/9.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Sql server 如何在不重复切分的情况下缩放数据库中的文字?_Sql Server_Database_Performance_Scaling_Sharding - Fatal编程技术网

Sql server 如何在不重复切分的情况下缩放数据库中的文字?

Sql server 如何在不重复切分的情况下缩放数据库中的文字?,sql-server,database,performance,scaling,sharding,Sql Server,Database,Performance,Scaling,Sharding,您如何在不重复切分的情况下扩展书写(特别是SQL Server 2008)?通常。。。避免在大表中使用索引和外键。索引列上的每次插入/更新都意味着部分重建索引,有时这可能会非常昂贵。当然,您必须权衡查询速度和写入速度,但这是数据库设计中的一个已知问题。您可以将其与具有某种缓存查询机制的NoSQL数据库相结合。可能是一个快速的NoSQL系统位于您的事务系统前面 另一种选择是使用事务一次完成多个写入操作,当您提交事务时,将重建索引,但每个事务只重建一次,而不是每次写入一次。为什么不碎片化?代码中的复

您如何在不重复切分的情况下扩展书写(特别是SQL Server 2008)?

通常。。。避免在大表中使用索引和外键。索引列上的每次插入/更新都意味着部分重建索引,有时这可能会非常昂贵。当然,您必须权衡查询速度和写入速度,但这是数据库设计中的一个已知问题。您可以将其与具有某种缓存查询机制的NoSQL数据库相结合。可能是一个快速的NoSQL系统位于您的事务系统前面


另一种选择是使用事务一次完成多个写入操作,当您提交事务时,将重建索引,但每个事务只重建一次,而不是每次写入一次。

为什么不碎片化?代码中的复杂性可以通过使用透明的分片工具来避免,这可以减轻与分片相关的所有繁重工作。
查看更多信息

事务技巧非常好,谢谢:)你是说NoSQL缓存读取查询,对吗?是的,我是说。有个打字错误。