Monday, March 12, 2012

How big is my log?

i'm trying to do a bcp load of a database. i'm *trying* to get the bcp load
to be non-logged. But there is no way to tell if it actually is logging the
load or not.
So i assume i should continously run some query to tell me the transaction
log size/used/free.
What is the command to get transaction log size?
You can run the next DBCC statment and you can get the size for the T-logs
dbcc SQLPERF(LOGSPACE)
if you want to know only the size of the current t-log , then you should to
use this:
SP_helpfile <LOG_FILE_NAME>
Pancho
"Ian Boyd" wrote:

> i'm trying to do a bcp load of a database. i'm *trying* to get the bcp load
> to be non-logged. But there is no way to tell if it actually is logging the
> load or not.
> So i assume i should continously run some query to tell me the transaction
> log size/used/free.
>
> What is the command to get transaction log size?
>
>
|||Hi Ian,
If its possible, you can change the recovery mode of the database to simple,
which will not log the BCP transactions. And you can revert back the recovery
mode.
The other alternative is, let the transaction log grow (if you have enough
space), and then truncate the log at the later stage.
The above solution is based on the assumption that currently you have Full
recovery mode on the database.
Thanks
Yogish

No comments:

Post a Comment