Upgrade from CRM 2011 to 2013 fails with “Subquery returned more than 1 value. Not Permitted CRM 4.0″

We recently stumbled upon an issue when upgrading a customer from CRM 4.0 to CRM 2013. As is required, you must first upgrade the 4.0 database to 2011 and then from 2011 to 2013. The 4.0 to 2011 upgrade succeeded without error but threw an error when going from 2011 to 2013. 2013 was on update rollup 2. The error thrown was:

Error| Installer Complete: OrganizationUpgrader – Error encountered
14:56:47| Error| Exception occured during Microsoft.Crm.Tools.Admin.OrganizationUpgrader: Error.ActionFailed Microsoft.Crm.Tools.Admin.InstallDatabaseUpdatesAction
InnerException: System.Data.SqlClient.SqlException (0x80131904): Subquery returned more than 1 value. This is not permitted when the subquery follows =, !=, <, <= , >, >= or when the subquery is used as an expression.
Subquery returned more than 1 value. This is not permitted when the subquery follows =, !=, <, <= , >, >= or when the subquery is used as an expression.

The statement has been terminated.

We upgraded the database from 4.0 to 2011 one afternoon and then tried going from 2011 to 2013 the following morning. As it turns out, CRM 2013 contains a query that checks to see if an organization is a new organization or an upgrade by checking the CreatedOn field of the system solution. It does this by seeing if the CreatedOn date/time is within one day (24 hours) of the current time. If the CreatedOn date of the System Solution is within 24 hours, it is considered a new organization. Here is the query:

IF EXISTS (SELECT * FROM SolutionBase WHERE SolutionId=’FD140AAD-4DF4-11DD-BD17-0019B9312238′
AND CreatedOn >= DATEADD(day, -1, GETUTCDATE()))

(This query goes on to Update prvAppendToOpportunity depth to global on sales person role and update prvAppendToQuote, prvAppendToOrder, prvAppendToInvoice to local on sales person role.)

When the 4.0 database is upgraded to 2011, it sets the CreatedOn date/time to whatever the UTC date/time is of that upgrade. So when going from 2011 to 2013 it sees the new date/time resulting from the upgrade to 2011 and considers it a new organization and errors out on the above query. Below is the query that can be run to check the CreatedOn date of your 2011 database.


The easy solution to this is to just wait 24 hours between the upgrade stages but if you are in a time crunch or minimizing down time for a go-live, you can update the CreatedOn date/time of the system solution directly in the 2011 database. Remember that the time is in UTC, changing the date back one day should be easier than trying to figure out the time difference in your time zone. However, keep in mind that updating fields directly through SQL is not a change supported by Microsoft so this is done at your own risk! Not sure if this issue is isolated to just Update Rollup 2 or if this occurs with 2013 RTM, Update Rollup 1, or Service Pack 1 yet.

Thanks to my young CRM Jedi Gage Pennisi for putting the details together!

CRM 2011: Online to On Premise – Import & Upgrade Error Windows Live ID

Recently, we have had to move some customers from CRM 2011 Online to CRM 2011 On Premise. It turns out the upgrade was failing around the mapping users. It turns out that the CRM 2011 Online uses a field called Windowsliveid. This is basically used in place of the domain\login fields that are used on premise. Having them together causes the upgrade to fail.

So, we need fix this via SQL update the organization before importing it into CRM 2011. From SQL Management Studio, open the CRM Organization database, and click new query. You can select from the systemuser base and scroll over to see the windowslive ID is populated or not. We can now replace that field with a null as it would be for a standard CRM 2011 On Premise Implementation following the syntax below. Now
proceed with your import of your database.

Please review my blog for dealing with removing Enterprise SQL Server Audit controls from the Database as well if you have importing to a standard SQL Server. Microsoft has since updated the request form to indicate what version of SQL you are migrating to, to avoid this issue in the future. Enjoy!

CRM 2011 Upgrade Failure: The full-text component is not installed on SQL Server, Word Breaker Not Installed

A common error when upgrading or installing CRM 2011:








This error can be resolved by modifying the existing SQL server installation. From Control panel, click add/remove programs, click on SQL Server installation, change/ add features. You will be prompted for the original install media so make sure you have it mounted and avaiable. Select add new features to SQL instance, choose instance that CRM was installed on, and check the box for Full-Text indexing.

The SQL wizard will run some checks and apply your changes. Once completed, Now start and stop SQL service, and make sure to turn back on the SQL Agent (it’s turned off during installation changes). Re-run your CRM setup by pressing back and next, and both errors will go away! Enjoy!



CRM 2011 Rollup 5 Install Error: Method not found: ‘Void Microsoft.Xrm.Sdk.”

When attempting to update your CRM 2011 Server to CRM 2011 Rollup 4 or 5, you receive an error message “Generic Error” upon reboot. After reviewing event logs you see an error stating “Method Not found: Void. Microsoft.Xrm.XXXXX”.

The fix is to use the GACUTIL for the .NET 4.0 framework and re-register 2 dlls from the CRM\Bin directory on the CRM server.

From a command prompt, go to:

C:\Program Files\Microsoft SDKs\Windows\v7.1\Bin\NETFX 4.0 Tools

gacutil /i “C:\Program Files\Microsoft Dynamics CRM\CRMWeb\bin\Microsoft.Xrm.Sdk.dll”

This will register the missing .DLL. Finally issue an IIS reset and start using your CRM Again. You can download the Windows 7 .NET Framework 4.0 Gacutil (Windows 2008 as well) from this link:


Problems Resolving Cases after upgrade to CRM 2011?

Are you having problems resolving cases after CRM 2011? The key is in the error file, it states Allotment overage is invalid.

This leads to the contractbase. When this data is upgraded from CRM 4 the values are NULL. CRM 2011 does not want the null value. Simply update the existing contractbase using the query below:

update ContractDetailBase set AllotmentsOverage = ISNULL(AllotmentsOverage, 0);

All new cases after the upgrade will not be effected! Enjoy!