Even though from SQL manager we have the option to shrink database log files, sometimes it does not work as the log files size is big. Then you need to use TSQL statements to do this. I have given below such a statement that can be used to do so.
USE Test1
GO
DBCC SHRINKFILE(Test1_log, 10)
BACKUP LOG Test1 WITH TRUNCATE_ONLY
DBCC SHRINKFILE(Test1_log, 10)
GO
if you do not know the log file name use the following command to find it.
select * from sys.database_files
I was helped by the following link.
http://blog.sqlauthority.com/2006/12/30/sql-server-shrinking-truncate-log-file-log-full/
This blog describes mostly about the work (CRM 365, CRM 2016, CRM 2015, CRM2011, CRM 4.0, CRM 3.0, C#,Javascript and SQL Server) i do.
Subscribe to:
Post Comments (Atom)
Retrieving Calendar of a Bookable Resource in Dynamics
There are occasions where we need to retrieve working days and working times of a resource in Dynamics grammatically. This is quite possible...
-
There is a bit of change in CRM 2011 than CRM 4. The code is below. Microsoft.Xrm.Sdk. EntityReference Moniker1 = new Microsoft.Xrm.S...
-
When you create a new security role from scratch and then assign only that role to a system user and when you log to the CRM site you might ...
-
There are occasions where we need to retrieve working days and working times of a resource in Dynamics grammatically. This is quite possible...
No comments:
Post a Comment