You've set a default, not a constraint (although a default is a contrait).

Not sure how to do this myself mind...

Adrian

-----Original Message-----
From: Les Mizzell [mailto:[EMAIL PROTECTED]
Sent: 12 September 2008 19:30
To: CF-Talk
Subject: Re: A Little Confusion on CFQUERYPARAM and Nulls...


OK, if I set my column "link_sort" with a default value of "99", and put 
this in my query...

link_sort =
    <cfqueryparam
     value="#Form["sortORD_#myIDX#"]#"
     cfsqltype="CF_SQL_VARCHAR"
     null="#not len(Form["sortORD_#myIDX#"])#">

.....and submit a blank form field - it inserts a NULL instead of the "99" 
default value.

What's wrong?

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:312459
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

Reply via email to