The upgraded database schema doesn’t match the TargetSchema – SharePoint Products Configuration Wizard

Problem

Failed to upgrade SharePoint Products.
This is a critical task. You have to fix the failures before you can continue. Follow this link for more information about how to troubleshoot upgrade failures:


An exception of type Microsoft.SharePoint.PostSetupConfiguration.PostSetupConfigurationTaskException was thrown.
Additional exception information: 
Upgrade [SPContentDatabase Name=WSS_Content] failed.	(EventID:an59t)
Exception: The upgraded database schema doesn't match the TargetSchema	(EventID:an59t)
Upgrade Timer job is exiting due to exception: Microsoft.SharePoint.Upgrade.SPUpgradeException:
The upgraded database schema doesn't match the TargetSchema

Solution

1. Use the following PowerShell script to upgrade all content databases:

Get-SPContentDatabase | Upgrade-SPContentDatabase -Confirm:$false

2. Run SharePoint Products Configuration Wizard again