Would be nice if the parameters that already exists were reused.
I believe the only change required for this are to move away from IList to IList
and use this in AppendRowsAsValues
var parameter = value?.GetType().IsValueType == true ? parameters.FirstOrDefault(x => x.Value == value) : null;
var paramName = parameter?.ParameterName ?? $"{paramPattern}{i}";
if (parameter == null)
{
var param = command.CreateParameter();
param.ParameterName = paramName;
param.Value = value;
parameters.Add(param);
i++;
}
sb.Append(paramName);
Would be nice if the parameters that already exists were reused. I believe the only change required for this are to move away from IList to IList
and use this in AppendRowsAsValues