Posts

Showing posts from 2017

SQL Server 2017 Installation Issue - VS Shell installation has failed with exit code 1638

Tried to install SQL Server on a new laptop and ran into this issue of unable to install VS shell. Followed this link to uninstall C++ runtime 2017 first and then SQL Server installation succeeded. https://dba.stackexchange.com/questions/190090/help-installing-sql-server-2017-vs-shell-installation-has-failed-with-exit-cod Remember to reinstall the C++ run time 2017 afterwards, so that VS2017 still works.

Devops with VSTS series video

https://blogs.msdn.microsoft.com/devops/2017/11/22/devops-and-vsts-videos-from-connect-2017/?utm_source=vs_developer_news&utm_medium=referral

SSRS issue on SQL Server 2012 SP3 -The version of the report server database is either in a format that is not valid, or it cannot be read

When windows update pushed SQL Server 2012 SP3 to the database server on the weekend, we received an error on SSRS: "The version of the report server database is either in a format that is not valid, or it cannot be read." I googled around and found this post on TechNet: https://social.technet.microsoft.com/wiki/contents/articles/32360.sspr-troubleshooting-the-version-of-the-report-server-database-is-either-in-a-format-that-is-not-valid-or-it-cannot-be-read.aspx I was surprised that a major SP would contain such an issue as most IT shops won't bother with the many CUs and choose to stay with SPs. The fix is upgrade to SP3 CU6 for us. Microsoft recommends to go with the latest CU, which is CU9. List of SQL Server Versions for reference:  http://sqlserverbuilds.blogspot.ca/

Move TFS Database to another SQL Instance

Some high level steps involved in moving TFS Database to another instance. Tuesday, March 28, 2017 3:13 PM iisreset /stop TfsServiceControl.exe quiesce tfsconfig remapdbs /databasename:{TFSServerName}\{SQLInstanceName};Tfs_Configuration /SQLInstances:{TFSServerName}\{SQLInstanceName} /AnalysisInstance:{TFSServerName}\{SQLInstanceName} /AnalysisDatabaseName:TFS_Analysis tfsconfig repairjobqueueTFSCOnfig Accounts /ResetOwner /SQLInstance:{TFSServerName}\{SQLInstanceName} /DatabaseName:TFS_Configuration TFSCOnfig Accounts /ResetOwner /SQLInstance:{TFSServerName}\{SQLInstanceName} /DatabaseName:TFS_Configuration TFSConfig RegisterDB /SQLInstance:{TFSServerName}\{SQLInstanceName} /databaseName:TFS_Configuration IISReset TFSServiceControl unquiesce

SQL Server Management Studio Start Debug Error: coloader80.dll

I got this error complains the coloader80.dll was not installed properly every time I install a new version of Visual Studio. The dll is in the IDE folder, so all I need to do is re-register the dll from the latest version of VS. C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE>regsvr32 coloader80.dll

Parse HTML code and save formatted text to Excel cell

I created a TFS hierarchical style report to show  User Stories Test Cases The report works well, however it lists the Test Step in HTML format.  When I export the report to Excel through VS, the HTML is not displayed in user friendly format.  I started to google around for solutions, and these are the steps: Select the HTML and send to clipboard Paste back to Excel with "Paste Special" to preserve the format When paste multiple lines of text, excel puts them in multiple rows, and the vba collects all the rows and puts them back to one row These are the protocol code: Private Sub Convert_Click() Dim rng As Range Set rng = ActiveSheet.Range("G3") Worksheet_Change rng, ActiveSheetEnd Sub Private Sub Worksheet_Change(ByVal Target As Range, ByVal sht As Worksheet) Dim objData As DataObject ' Set a reference to MS Forms 2.0 Dim sHTML As String Dim sSelAdd As String Dim i As Long Dim txt As String Application.EnableEvents = Fa

SP optimization with TVF, View

Had problem with a SP, SP has a few parameters SP unions three queries and then filter by a parameter and then return data  One of the three queries links a TVF with a few tables The TVF links a standard view with a few tables The View links several tables, however not all tables are used by the TVF Symptom: One table used by the TVF has many scan count and slows down the SP Optimization options: Bring the parameter to the three queries referenced by the SP - no effect Modify the TVF and pass in the SP parameter - Speed up 4x Replace the view with the base table and remove unused tables - Speed up 4x