Posted by Monday, February 6, 2017on
EF Code-First uses conventions to beautifully create identity field for us when defining int primary keys. However, there are times that we don't want the database generate the primary key values for us. Here are two ways to avoid Code-First set identity fields on int primary keys.
Posted by Wednesday, February 1, 2017on
Seems it a very common problem from Excel (and sometimes Power Point) that you set all correct, nice margins, adjust columns to fit into the printing area, in preview looks fine, you save as (or print as) PDF, and then... your find out extra margins on the left and right!!!
Posted by Monday, June 27, 2011on
We recently had some problems with one our host servers, they set a limitation of 100 MB memory for dedicated application pools. While is understandable they set such a limit, problem is that limit is very low for .net mvc websites, since an empty website already needs 30 MB, so as soon as you add database and get traffic, it easy goes above 100 MB, causing the application pool to restart and session is lost having all your visitors logged out.
Posted by Saturday, June 18, 2011on
When defining our model using POCO classes, we just use string for all our string model properties that later are created as nvarchar fields in the database. String types max length is 4,000 characters, so, what if I need something longer, for example for a blog content field? Then, we need ntext.