hello,
I've got an insert statement that keeps failing when I call it from a SQL 2005 stored procedure. (This insert statement attempts to put 22,000 records in a table.)
After I try to call the stored procedure, I check the SQL logs for information. It tells me: "Autogrow of file [dbname_log] in database [dbname] was cancelled by user or timed out after 407 miliseconds. Use Alter Database to set a smaller filegrowth value for this file or explicity set a new size."
I've tried several things. I've logged in as 'sa', and run this command:
ALTER DATABASE [dbname]
MODIFY FILE (NAME = [dbname_log], Filegrowth=10%)
It still produces the error. I've also tried:
ALTER DATABASE [dbname]
MODIFY FILE (NAME = [dbname_log], MAXSIZE=UNLIMITED)
This gives me the same error.
I've also tried to right-click the database name from the 2005 Server Management Console. I click on "files". I click on the button associated with the log file. I indicate that "Enable Autogrowth" is checked. Also, I check off the Restricted Growth checkbox and check on Unrestricted File Growth. I click "OK". Guess what, when I look again at the log file it still says "restricted growth."
I've tried to truncate my log many times, running these commands:
Use [dbname]
GO
DBCC Shrinkfile('[dbname_log]', 1)
BACKUP Log [dbname] with TRUNCATE ONLY
DBCC Shrinkfile('[dbname_log]', 1)
The output that appears beneath these commands indicate that the log file is the same size as its minimum size.
So, does anyone have an idea how I can configure my log file so that I can run my insert statement?
thanks.
I've got an insert statement that keeps failing when I call it from a SQL 2005 stored procedure. (This insert statement attempts to put 22,000 records in a table.)
After I try to call the stored procedure, I check the SQL logs for information. It tells me: "Autogrow of file [dbname_log] in database [dbname] was cancelled by user or timed out after 407 miliseconds. Use Alter Database to set a smaller filegrowth value for this file or explicity set a new size."
I've tried several things. I've logged in as 'sa', and run this command:
ALTER DATABASE [dbname]
MODIFY FILE (NAME = [dbname_log], Filegrowth=10%)
It still produces the error. I've also tried:
ALTER DATABASE [dbname]
MODIFY FILE (NAME = [dbname_log], MAXSIZE=UNLIMITED)
This gives me the same error.
I've also tried to right-click the database name from the 2005 Server Management Console. I click on "files". I click on the button associated with the log file. I indicate that "Enable Autogrowth" is checked. Also, I check off the Restricted Growth checkbox and check on Unrestricted File Growth. I click "OK". Guess what, when I look again at the log file it still says "restricted growth."
I've tried to truncate my log many times, running these commands:
Use [dbname]
GO
DBCC Shrinkfile('[dbname_log]', 1)
BACKUP Log [dbname] with TRUNCATE ONLY
DBCC Shrinkfile('[dbname_log]', 1)
The output that appears beneath these commands indicate that the log file is the same size as its minimum size.
So, does anyone have an idea how I can configure my log file so that I can run my insert statement?
thanks.