String or binary data would be truncated. The statement has been terminated - Error

String or binary data would be truncated. The statement has been terminated - Error

  

Getting the truncation error during CreateUpdate. I understand that this could be because of data that is bigger that the target field. However the logs does not tell me what field is having the issue. I have used SubStr and tried to make sure all database fields are assigned data within the length constraints. 

IS there a way to expand the log information to show the actual database field that is having the issue. 

Thanks. See log below.


String or binary data would be truncated.
The statement has been terminated.
Environment InformationeSpaceVer: 580 (Id=1361, PubId=1417, CompiledWith=10.0.105.0)
RequestUrl: http://afx1hw010.outsystemscloud.com/Wildly/_TimerHandler.asmx (Method: POST)
AppDomain: /LM/W3SVC/11/ROOT/Wildly-73-131244911403666657
FilePath: C:\OutSystems\Sandboxes\AFX1HW010\Platform Server\running\Wildly\
ClientIp: 127.0.0.1
Locale: en-US
DateFormat: yyyy-MM-dd
PID: 3784 ('w3wp', Started='11/15/2016 5:21:18 PM', Priv=758Mb, Virt=18195Mb)
TID: 476
Thread Name:
.NET: 4.0.30319.42000
Stack: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.SqlDataReader.TryConsumeMetaData()
   at System.Data.SqlClient.SqlDataReader.get_MetaData()
   at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString)
   at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, 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 asyncWrite)
   at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method)
   at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method)
   at OutSystems.HubEdition.DatabaseProvider.SqlServer.ExecutionService.ExecutionService.ExecuteReader(IDbCommand cmd)
   at OutSystems.HubEdition.DatabaseProvider.SqlServer.ExecutionService.ExecutionService.ExecuteScalar(IDbCommand cmd)
   at OutSystems.Internal.Db.Command.ExecuteScalar(String description, Boolean isApplication, Boolean skipLog, Boolean applyTransformationsToParameters)
   at ssWildly.ExtendedActions.CreateOrUpdateWildlyTaxonomyData(HeContext heContext, BitArray usedFields, RCWildlyTaxonomyDataRecord inParamSource, Int64& outParamId)
   at ssWildly.Actions.ActionSyncWildlyDataServerAction(HeContext heContext, String inParamLoggedUser)

The error is originated by the database engine (Sql Server in your case), so there's no option to provide more details in OutSystems. Try to use the debugger to inspect the record just before it's saved.