Database Shrink and Database Backups
Issue: Database shrink cause database full and log backups to fail. Fix: Make sure to disable database backups when running database shrink.
Issue: Database shrink cause database full and log backups to fail. Fix: Make sure to disable database backups when running database shrink.
Make sure the DDL file is place in this folder and has the following property set… D:\Program Files\Microsoft SQL Server Reporting Services\SSRS\ReportServer\bin File -> Properties -> General -> Unblock checked Checked the “Unblock” in file permission, restart SSRS services, and try uploading the RDL file again. Sources: https://forums.ivanti.com/s/article/Error-when-attempting-to-preview-a-report-in-BIDS-Failed-to-grant-permission-to-execute-Exception-from-HRESULT-0x80131418?language=en_US https://learn.microsoft.com/en-us/sql/reporting-services/custom-assemblies/deploying-a-custom-assembly?view=sql-server-ver16
Issue: Getting the following error when try to upload a RDL file to SSRS that uses a custom DDL file… Could not load file or assembly or one of its dependencies. Failed to grant permission to execute. Fix: Make sure the DDL file is place in this folder and has the following property set… D:\Program... » read more
Error: Error details:Error installing SQL Server Database Engine Services Instance FeaturesCould not find the Database Engine startup handle.Error code: 0x851A0019 Getting the following error in Event Viewer when trying to install SQL Server… Cannot use file ‘D:\Program Files\Microsoft SQL Server\MSSQL16.MSSQLSERVER\MSSQL\DATA\mastlog.ldf’ because it was originally formatted with sector size 4096 and is now on a volume... » read more
Error: TITLE: Microsoft SQL Server 2022 Setup —————————— The following error has occurred: Could not find the Database Engine startup handle. For help, click: https://go.microsoft.com/fwlink?LinkID=2209051&ProdName=Microsoft%20SQL%20Server&EvtSrc=setup.rll&EvtID=50000&ProdVer=16.0.1000.6&EvtType=0xD15B4EB2%25400x4BDAF9BA%25401306%254025 Issue: Unable to start SQL services. Check Windows “Event Viewer” for errors. Event Viewer Log: Cannot use file ‘D:\Program Files\Microsoft SQL Server\MSSQL16.MSSQLSERVER\MSSQL\DATA\master.mdf’ because it was originally formatted with sector size... » read more
Source: https://michaeljswart.com/2014/09/take-care-when-scripting-batches/ The Straight Query Suppose we want to remove sales data from FactOnlineSales for the “Worcester Company” whose CustomerKey = 19036. That’s a simple delete statement: DELETE FactOnlineSales WHERE CustomerKey = 19036; This delete statement runs an unacceptably long time. It scans the clustered index and performs 46,650 logical reads and I’m worried about concurrency issues. Naive... » read more
SQLCMD mode is a script execution mode that simulates the sqlcmd.exe environment and therefore accepts some commands that are not part of T-SQL language. Just enable SQLCMD mode in SSMS (Query menu -> SQLCMD Mode) and the query will run fine. SSMS can also be configured to automatically enable SQLCMD mode in Tools menu -> Options... » read more
Error in Azure Function VS projects: There is no Functions runtime available that matches the version specified in the project. Fix: I eventually found the solution for my case and I will post it here if anyone else faces it. As mentioned in a comment from this Github issue, I had to go to Tools -> Options... » read more
Explanation: Set the directories: Replace "C:\SourceDirectory" and "C:\DestinationDirectory" with the actual source and destination paths. Set file types: Replace ` “.txt”, “.log”` with the desired file extensions. Set the number of days: Modify $days to specify the age threshold for moving files. Get the current date: The script calculates the cutoff date by subtracting the specified number of days from the current date. Get the... » read more
https://serverfault.com/questions/31554/how-to-check-progress-of-dbcc-shrinkfile