Hey,
While creating a lead, I get a weird Exception.
As soon as the subject field exceeds 51 chars a SQLException is thrown. But in CRM the maximum length of this field is set to 300 chars.
Has anyone an idea?
System: CRM-Online
Early/latebound: Earlybound
{Exception details: ErrorCode: 0x80073001 Message: Sql error: A validation error occurred. A string value provided is too long. CRM ErrorCode: -2147012607 Sql ErrorCode: -2146232060 Sql Number: 8152 TimeStamp: 2019-06-17T09:54:28.1568230Z -- Exception details: ErrorCode: 0x80073001 Message: Sql error: A validation error occurred. A string value provided is too long. CRM ErrorCode: -2147012607 Sql ErrorCode: -2146232060 Sql Number: 8152 TimeStamp: 2019-06-17T09:54:28.1568230Z -- Exception details: ErrorCode: 0x80073001 Message: Sql error: A validation error occurred. A string value provided is too long. CRM ErrorCode: -2147012607 Sql ErrorCode: -2146232060 Sql Number: 8152 TimeStamp: 2019-06-17T09:54:28.1568230Z -- Exception details: ErrorCode: 0x80040216 Message: Exception output:: System.Data.SqlClient.SqlException (0x80131904): String or binary data would be truncated. The statement has been terminated. at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction) at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose) at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady) at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString, Boolean isInternal, Boolean forDescribeParameterEncryption, Boolean shouldCacheForAlwaysEncrypted) at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, Boolean inRetry, SqlDataReader ds, Boolean describeParameterEncryptionRequest) at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean& usedCache, Boolean asyncWrite, Boolean inRetry) at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(TaskCompletionSource`1 completion, String methodName, Boolean sendToPipe, Int32 timeout, Boolean& usedCache, Boolean asyncWrite, Boolean inRetry) at System.Data.SqlClient.SqlCommand.ExecuteNonQuery() at Microsoft.Crm.CrmDbConnection.LockConnectionAndExecuteMethod[TResult](IDbConnection connection, Func`1 executeMethod) at Microsoft.Crm.CrmDbConnection.InternalExecuteWithRetry[TResult](Func`1 ExecuteMethod, IDbCommand command, ICrmTransaction crmTransaction) at Microsoft.Crm.CrmDbConnection.<>c__DisplayClass122_0.<InternalExecuteNonQuery>b__0() at Microsoft.PowerApps.CoreFramework.ActivityLoggerExtensions.Execute[TResult](ILogger logger, EventId eventId, ActivityType activityType, Func`1 func, IEnumerable`1 additionalCustomProperties) at Microsoft.Xrm.Telemetry.XrmTelemetryExtensions.Execute[TResult](ILogger logger, XrmTelemetryActivityType activityType, Func`1 func) at Microsoft.Crm.Platform.Server.DataEngine.SqlDataAccessManager.ExecuteNonQuery(IDbCommand command, ISqlExecutionContext context, Int32 sourceLineNumber, String memberName, String sourceFilePath) at Microsoft.Crm.Platform.Server.DataEngine.EntityCrudManager.Create(IBusinessEntity entity, ExecutionContext context) at Microsoft.Crm.BusinessEntities.BusinessProcessObject.DoCreate(IBusinessEntity entity, ExecutionContext context) ClientConnectionId:419f89ff-ca05-4488-82f1-b3fd286dbb7c Error Number:8152,State:13,Class:16 ClientConnectionId before routing:dc443f59-ff1a-44ed-b79c-078a9fce65bf Routing Destination:e6c362a837bc.tr641.northeurope1-a.worker.database.windows.net,11042 Error(s) details: Class: 0x10 LineNumber: 1 Message: String or binary data would be truncated. Number: 8152 Procedure: Server: e6c362a837bc.tr641.northeurope1-a.worker.database.windows.net,11042 Source: .Net SqlClient Data Provider State: 13 ToString(): System.Data.SqlClient.SqlError: String or binary data would be truncated. -- Class: 0x0 LineNumber: 1 Message: The statement has been terminated. Number: 3621 Procedure: Server: e6c362a837bc.tr641.northeurope1-a.worker.database.windows.net,11042 Source: .Net SqlClient Data Provider State: 0 ToString(): System.Data.SqlClient.SqlError: The statement has been terminated. -- : Microsoft Dynamics CRM has experienced an error. Reference number for administrators or support: #F01E7DEE TimeStamp: 2019-06-17T09:54:28.1568230Z -- }
↧
SQLException due to too long value. But MaxLength not exceeded
↧