Re: SQL Query problem take ages to run
From: -Permood (Permood_at_discussions.microsoft.com)
Date: 12/11/04
- Next message: Ken: "open_tran = 1"
- Previous message: Steve Kass: "Re: set based guru's help wanted"
- In reply to: maxl_at_msn.com: "Re: SQL Query problem take ages to run"
- Next in thread: Max: "Re: SQL Query problem take ages to run"
- Reply: Max: "Re: SQL Query problem take ages to run"
- Messages sorted by: [ date ] [ thread ]
Date: Sat, 11 Dec 2004 10:37:02 -0800
Thanks you Louis, and Maxl.
is there any way, i can turn off loging when i use this query to stop this
transcation to be loged. second I am not very expert in dba type tasks, so to
check i/o is bit advance task for me, what should be my first step being a
new user to sql server.
"maxl@msn.com" wrote:
> Another consideration is the amount of disk i/o this INSERT is
> generating. SQL Server will allocate space in TempDB, the target
> database, and the target database transaction log. Since you are doing
> this as a single transaction, your transaction log will be larger than
> the resulting table data and TempDB will need space for any temporary
> tables created as a result of the Execution Plan.
>
> If you allow SQL Server to perform the allocations as needed, you will
> end up with a higher degree of disk fragmentation and SQL Server data
> structure allocation fragmentation.
>
> The DISTINCT will compound all this.
>
> You should not only avoid using DISTINCT, but also pre-allocate your
> databases.
>
>
- Next message: Ken: "open_tran = 1"
- Previous message: Steve Kass: "Re: set based guru's help wanted"
- In reply to: maxl_at_msn.com: "Re: SQL Query problem take ages to run"
- Next in thread: Max: "Re: SQL Query problem take ages to run"
- Reply: Max: "Re: SQL Query problem take ages to run"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|