SqlParameter and DBNull.Value - possible bug?



Is following behaviour by design or is it a bug?
For shure breaking change from framework 1.1.

Try under framework => 2.0
SqlParameter param = new SqlParameter("Test", DbType.Int32);
Console.WriteLine("Value: {0}, Type: {1}",param.Value, param.DbType);
param.Value = DBNull.Value;
Console.WriteLine("Value: {0}, Type: {1} --- WTF",param.Value, param.DbType);
Console.ReadLine();
.



Relevant Pages

  • Re: OODesign - OPF, design pattern
    ... What I had in mind were very specific design patterns, ... It's under their control, for goodness ... but once I had reached a point where I could stop "tweaking" the framework to handle scenarios that I hadn't previously thought of the development time suddenly increased dramatically. ... once you zoom in even just a little, OO design reveals more layers. ...
    (borland.public.delphi.non-technical)
  • Re: Books / Articles on Embedded SW Architecture
    ... and dirty patches must be done to already fixed architecture. ... decomposition, then there was a problem with the decomposition. ...</b