Thanks for the link - this was my first question on the forum
Hopefully this is all the info you need:
LLBLGenPro 1.0.2005.1 Final
Runtime file version 1.0.20051.60207
stacktrace:
An exception was caught during the execution of an action query: A severe error occurred on the current command. The results, if any, should be discarded.. Check InnerException, QueryExecuted and Parameters of this exception to examine the cause of this exception. : at SD.LLBLGen.Pro.ORMSupportClasses.ActionQuery.Execute() at SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase.ExecuteActionQuery(IActionQuery queryToExecute) at SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase.UpdateEntitiesDirectly(IEntity2 entityWithNewValues, IRelationPredicateBucket filterBucket)
Using Adapter Vs.NET 2003 C# template for SqlServer with a SqlServer 2000 database
MmClientEntity client = new MmClientEntity();
client.DoNotCall = true;
client.FTCDoNotCall = true;
client.Fields[(int) MmClientFieldIndex.DNCEffectiveDateTimeUTC].ExpressionToApply = (MmClientFields.CreatedDateTimeUTC + 90);
IPredicateExpression filter = new PredicateExpression();
filter.Add( PredicateFactory.CompareRange( MmClientFieldIndex.Phone, false, phoneNumbers) );
using (DataAccessAdapter adapter = new DataAccessAdapter())
{
return adapter.UpdateEntitiesDirectly(client, new RelationPredicateBucket(filter));
}
Here's the generated Query (I have truncated the paramter list to make it more readable and changed the phone number to be a fake:
UPDATE [MoneyMasters].[dbo].[mmClient] SET [DNCEffectiveDateTimeUTC]=[MoneyMasters].[dbo].[mmClient].[CreatedDateTimeUTC] + @LO30851,[DoNotCall]=@DoNotCall,[FTCDoNotCall]=@FTCDoNotCall WHERE ( ( ( [MoneyMasters].[dbo].[mmClient].[Phone] IN (@Phone2,.....,@Phone8363))))
Parameter: @LO30851 : Int32. Length: 0. Precision: 0. Scale: 0. Direction: Input. Value: 90.
Parameter: @DoNotCall : Boolean. Length: 0. Precision: 1. Scale: 0. Direction: Input. Value: True.
Parameter: @FTCDoNotCall : Boolean. Length: 0. Precision: 1. Scale: 0. Direction: Input. Value: True.
Parameter: @Phone2 : AnsiString. Length: 255. Precision: 0. Scale: 0. Direction: Input. Value: (555) 555-5555.
If I copy that into query analyzer and replace the parameter names with the values listed then the query runs OK and updates the rows.