04 April 2017

Should I go to Parameters.Add or to a simplified Parameters.AddWithValue?

For some developers, choosing between the two is just a matter of preferences because in fact there is no difference in terms of functionality between these two.

I disagree.

Providing only the type Parameters.AddWithValue, the compiler will just try to implicitly convert the input parameter to what is expected and it may cause you a performance issue.

No comments:

Post a Comment