Error: Data could not be saved. An error occurred while saving the source analysis rule: Error saving query view: A .NET Framework error occurred during execution of user defined routine or aggregate 'USP_LOADSPEC':

 Error: Data could not be saved.  An error occurred while saving the source analysis rule:  Error saving query view:  A .NET Framework error occurred during execution of user defined routine or aggregate 'USP_LOADSPEC':
 
System.Data.SqlClient.SqlException: Column names in each view or function must be unique. Column name 'VALUEGROUP' in view or function 'V_QUERY_MKTSOURCEANALYSISRULEDATA_09A6D736_2ACB_42FF_87DB_F4F92A2025E1' is specified more than once.
 
System.Data.SqlClient.SqlException:
 
   at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)
 
   at System.Data.SqlClient.SqlCommand.RunExecuteNonQuerySmi(Boolean sendToPipe)
 
   at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)
 
   at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
 
   at Blackbaud.AppFx.Platform.SqlClr.QueryViewSpecProcessor.ExecuteSqlNonQuery(String sqlToExecute)
 
   at Blackbaud.AppFx.Platform.SqlClr.QueryViewSpecProcessor.ProcessSpec(String specXml, String specExtensionXml, Nullable`1 changeAgentID)
 
   at Blackbaud.AppFx.Platform.SqlClr.QueryViewSpecCLR.ProcessSpec(String specXml, Nullable`1 changeAgentID, SqlBoolean skipValidation)
 
   at Blackbaud.AppFx.Platform.SqlClr.LoadSpec.LoadSpecAsString(String specXmlText, Nullable`1 changeAgentID, SqlString sourceName, SqlString itemName, SqlBoolean loadAsDependency, SqlBoolean forceReload, SqlBoolean processPageAlterations, SqlBoolean skipValidation, SqlBoolean compareToExistingSpecXml)
 
   at Blackbaud.AppFx.Platform.SqlClr.LoadSpec.LoadSpec(SqlXml specXml, Nullable`1 changeAgentID, SqlString sourceName, SqlString itemName, SqlBoolean loadAsDependency, SqlBoolean forceReload, SqlBoolean processPageAlterations, SqlBoolean skipValidation, SqlBoolean compareToExistingSpecXml)
 
. User transaction, if any, will be rolled back.
 
LOADSPEC ERROR:Column names in each view or function must be unique. Column name 'VALUEGROUP' in view or function 'V_QUERY_MKTSOURCEANALYSISRULEDATA_09A6D736_2ACB_42FF_87DB_F4F92A2025E1' is specified more than once.
 
This error occurs when updating the Source analysis rule in BBDM.
Download and install the latest patch, which contains all fixes from previous patches. If you are running an older version, download and install the latest version and then the patch. 

Environment

 2.93.2034.10
 2.94.1524, patch 20 ; 2.93.2034, patch 40

Was this article helpful?