disc_content表是海量数据,content_temp1是生成的表,
下列SQL语句还有提升速度和性能的空间吗?应该怎么写就能提升速度?CREATE procedure form_content_temp1
asif object_id('content_temp1') is not null drop table content_temp1
select disc_content_id,contentstructure,correspondingdiscid
into content_temp1
from disc_content order by contentstructure asc , correspondingdiscid asc
GO
下列SQL语句还有提升速度和性能的空间吗?应该怎么写就能提升速度?CREATE procedure form_content_temp1
asif object_id('content_temp1') is not null drop table content_temp1
select disc_content_id,contentstructure,correspondingdiscid
into content_temp1
from disc_content order by contentstructure asc , correspondingdiscid asc
GO
解决方案 »
- 求一个sql!---多谢了!
- sql(求和)碰到的问题
- 求一条update语句
- 请教一下,在存储过程中可以用OPENDATASOURCE吗?
- 怎样实现在数据表中存储大量的数据,急啊
- 如何写关联表查询语句
- 请教高手: SQL语句有无位操作命令???
- 有没有人了解SQL2005 里面的ROW_NUMBER() OVER (PARTITION BY方法,帮我解决下,谢谢
- 这个错误怎么搞定?如何在SQL Server2000通过SQL 语句写入TEXT字段(TEXT的内容海量)
- 有没有人知道如何直接用代码创建access数据库
- sql的insert和update两个语句同时执行时在程序里总是出错,求解
- 数据库默认排序 没规律如何解决???????
2:大数据量的插入,建议使用增量式的数据更新方式
http://www.cnblogs.com/worfdream/articles/3046377.html
要么你将contentstructure asc , correspondingdiscid asc这两个字段创建复合索引,并且指定按照asc排序。
另外,考虑到对系统表的影响,还是先创建content_temp1表,然后在insert比较好。