RSS

A Message Board, Guestbook, or Poll hosted for your website.
Iron Speed Technical Forums

Register Login New Posts Chat
 
Iron Speed > Forums > Code Customizations V3.X > I want to put blank / not NULL.
 
Username:  
Password:  
 
   
 


Thread Tools Search This Thread 
Reply
 
Author Comment
 
JimiJ
Avatar / Picture

MVP Developer
Registered: 03/31/05
Posts: 4,028

    04/12/08 at 02:39 AMReply with quote#16

if blank is extremely necessary, the way to do it is this:

Set 'na' as column default and create a simple After Insert-Trigger to reset it to blank (' ') when value is 'na'.

To make it easy for you this is the sample trigger:

AFTER INSERT

NOT FOR REPLICATION

AS

Begin

SET NOCOUNT ON;

Declare @f varchar(20)

IF EXISTS(SELECT * FROM inserted)

IF Not EXISTS(SELECT * FROM deleted)

Select @f = Field1 From Inserted

Begin

Update R SET Field1=

Case

When @f ='na' Then ''

Else @f

End

From tblData1 R Inner JOIN Inserted I

ON R.FieldID=I.FieldID

End

End


Cheers


__________________
Jaime Jegonia
JimiTron Software
JimiTron.Net | JimiTron.Com
expuser
Registered: 03/13/08
Posts: 48

    04/12/08 at 08:54 AMReply with quote#17

Thanks Jimi. I already went ahead by modifying the base classes. The idea is similar though.

afisher
Avatar / Picture

Co-Founder
Registered: 04/22/04
Posts: 2,455

    05/21/09 at 04:59 PMReply with quote#18

I believe this has been implemented or improved in V6.1.0 which was released on May 21, 2009.  Additional details are in the Release Notes page for this release on our website.  As always, please make sure you install V6.1.0 in a separate, new folder.  Also, you may need to regenerate your application…

 

Thanks!


__________________
Alan Fisher
Chairman
Iron Speed, Inc.
http://www.ironspeed.com
Previous Thread | Next Thread
Page 2 of 2    < 1  |  2
Reply

  Bookmarks  
Digg Diggdel.icio.us del.icio.usStumbleUpon StumbleUponGoogle Google

Download Iron Speed Designer

Privacy Statement