Print Page | Close Window

Nulls getting passed to the database on insert?

Printed From: IdeaBlade
Category: DevForce
Forum Name: DevForce Classic
Forum Discription: For .NET 2.0
URL: http://www.ideablade.com/forum/forum_posts.asp?TID=786
Printed Date: 28-Mar-2025 at 12:58pm


Topic: Nulls getting passed to the database on insert?
Posted By: Jon S
Subject: Nulls getting passed to the database on insert?
Date Posted: 25-Apr-2008 at 6:40am
I've got an entity that only includes three fields from a database table.  When I create a new entity, populate my three fields, and then save, I get an error: "can't save null value in field X".  This field 1) isn't included in my business object, 2) isn't nullable,  and 3) has a default value in the database.

Is DevForce trying to set it to null anyway?  What is the best solution for this?

Thanks!



Replies:
Posted By: davidklitzke
Date Posted: 25-Apr-2008 at 4:49pm

In the ORM Tool, set "Column Selection Options" to "AllowColumnSelection"

 
 
 



Print Page | Close Window