﻿<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>StrataFrame Forum » StrataFrame Application Framework - V1 » Enhancement Requests  » Default value in field</title><generator>InstantForum 2017-1 Final</generator><description>StrataFrame Forum</description><link>http://forum.strataframe.net/</link><webMaster>StrataFrame Forum</webMaster><lastBuildDate>Thu, 07 May 2026 07:47:32 GMT</lastBuildDate><ttl>20</ttl><item><title>Default value in field</title><link>http://forum.strataframe.net/FindPost31806.aspx</link><description>Hello,&lt;br/&gt;&lt;br/&gt;I use a default value for all my field in sql Server with DDT , i don't want null value.&lt;br/&gt;&lt;br/&gt;When i use this.MyBo.Add();&amp;nbsp; , i have a error when i save , cause Strata say me, cast is impossible on RUE_ID (my foreign key)&lt;br/&gt;if after the add i instantiate with 0 or -1 , it's ok, without this it's doesn't work.&lt;br/&gt;&lt;br/&gt;It's possible that Strata can instantiate with the default value when i use Add() method ?&lt;br/&gt;&lt;br/&gt;thanks&lt;br/&gt;Olivier,</description><pubDate>Fri, 08 Feb 2013 08:17:09 GMT</pubDate><dc:creator>Olivier</dc:creator></item><item><title>RE: Default value in field</title><link>http://forum.strataframe.net/FindPost31809.aspx</link><description>Hi Olivier,&lt;br/&gt;You have to handle the nulls in the Business Object Mapper and set the Null Value Option to one that fix your need, in my case I mostly use "Return Altername on Null" and set the appropriate value for my integer FK fields to 0 and strings to String.Empty</description><pubDate>Fri, 08 Feb 2013 08:17:09 GMT</pubDate><dc:creator>Edhy Rijo</dc:creator></item></channel></rss>