Showing posts with label Microsoft System Center Service Manager. Show all posts
Showing posts with label Microsoft System Center Service Manager. Show all posts

8/15/12

SQL 2008 Native Client Installation Error





I recently worked on a Microsoft System Center Service Manager 2012 upgrade project and on both of the management servers during the prerequisite installation the SQL Server 2008 Native Client installation would fail. After searching around through what seemed like hundreds of sites, I found a solution that works consistently.

Error Message - An error occurred during the installation of assembly 'Microsoft.VC80.CRT...




Export and delete the following registry keys...

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\SideBySide\Winners\x86_policy.8.0.microsoft.vc80 & vc90 entries…

[HKEY_LOCAL_MACHINE\COMPONENTS\DerivedData\Components\x86_policy.8.0.microsoft.vc80 & vc90 entries

[HKEY_LOCAL_MACHINE\COMPONENTS\WINNER\Components\x86_policy.8.0.microsoft.vc80 & vc90 entries.


Note: On my 2008 R2 Server the third set of keys was not present

Then run services.msc and set the "Windows Module Installer" to automatic and Reboot.
The installation will now complete successfully.

6/18/12

Cannot resolve the collation conflict between “SQL_Latin1_General_CP1_CI_AS” and “Latin1_General_100_CI_AS” in the equal to operation

Working in a Microsoft System Center Service Manager 2010 database I had added a couple of new tables for doing Business Hour Calculations ( see SQL Calculate Business Hours post). I added the tables calendar and holiday for the business hour calculations and when I attempted to execute my SQL function for doing the business hour calculation between date ranges I received the error.

After searching and searching I found a simple solution. First a useful query to determine what the collation is for a columns in a table. In my case I performed the query on the calendar table and day_name and day_number were both set incorrectly.


SELECT
    col.name, col.collation_name
FROM 
    sys.columns col
WHERE
    object_id = OBJECT_ID('YourTableName')




This query will return the collation for each column specified, for me it instantly helped my identify the collation conflict and I was able to execute the following query to correct the issue.


ALTER TABLE YourTableName
  ALTER COLUMN OffendingColumn
    VARCHAR(100) COLLATE Latin1_General_CI_AS NOT NULL


After I ran the alter statement, I tried the business hour function again and sure enough it worked perfectly.