Microsoft distributes Microsoft SQL Server 2012 fixes as one downloadable file. Because the fixes are cumulative, each new release contains all the hotfixes and all the security fixes that were included with the previous SQL Server 2012 fix release.
Symptoms
Assume that you install Microsoft SQL Server 2012 Remote Blob Store for an additional database on the same instance of SQL Server by using the command line. For example, you run the following command at the command line:
msiexec /qn /lvx* rbs_install_log_2.txt /i rbs.msi REMOTEBLOBENABLE=1 FILESTREAMPROVIDERENABLE=1 DBNAME="Database Name" FILESTREAMSTORENAME=FilestreamProvider_1 ADDLOCAL=EnableRBS,FilestreamRunScript DBINSTANCE="Domain\ServerName" In this scenario, this installation fails. Additionally, you receive an error message that resembles the following:RBS Error. Original Error: Number 2601, Severity 14, State 1, Procedure rbs_sp_add_blob_store, Line 64,
Message: Cannot insert duplicate key row in object 'mssqlrbs_resources.rbs_internal_blob_stores' with unique index 'rbs_internal_blob_stores_ix_name'. The duplicate key value is (FilestreamProvider_1).Transaction count after EXECUTE indicates a mismatching number of BEGIN and COMMIT statements. Previous count = 1, current count = 0.Cause
This issue occurs because the second installation uses incorrect values for variables that are derived from the first installation.
These variables store the FILESTREAM database name and the instance name. During the second installation, the values of these variables are retrieved from the registry and overwrite the values that you define in the command line.Resolution
Cumulative update information
Cumulative Update 2 for SQL Server 2012 SP1
The fix for this issue was first released in Cumulative Update 2. For more information about how to obtain this cumulative update package for SQL Server 2012 SP1, click the following article number to view the article in the Microsoft Knowledge Base:
2790947 Cumulative update package 2 for SQL Server 2012 Service Pack 1Note Because the builds are cumulative, each new fix release contains all the hotfixes and all the security fixes that were included with the previous SQL Server 2012 SP1 fix release. We recommend that you consider applying the most recent fix release that contains this hotfix. For more information, click the following article number to view the article in the Microsoft Knowledge Base:
2772858 The SQL Server 2012 builds that were released after SQL Server 2012 Service Pack 1 was released
Cumulative Update 5 for SQL Server 2012
The fix for this issue was first released in Cumulative Update 5. For more information about how to obtain this cumulative update package for SQL Server 2012, click the following article number to view the article in the Microsoft Knowledge Base:
2777772 Cumulative update package 5 for SQL Server 2012Note Because the builds are cumulative, each new fix release contains all the hotfixes and all the security fixes that were included with the previous SQL Server 2012 fix release. We recommend that you consider applying the most recent fix release that contains this hotfix. For more information, click the following article number to view the article in the Microsoft Knowledge Base:
2692828 The SQL Server 2012 builds that were released after SQL Server 2012 was released
Workaround
To work around the issue, install the Remote Blob Store by using the UI mode instead of using the command line.
Status
Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.