I'm having a strange issue with postgresql...

I have a database table containing a field defined as follows:

ABSTRACT text not null default ''

When I insert data, I use cfqueryparam as follows:

<cfqueryparam cfsqltype="cf_sql_longvarchar" 
value="#arguments.details.abstract#">

And I'm seeing this error:

[Macromedia][SequeLink JDBC Driver][ODBC Socket]ERROR: ExecInsert: Fail 
to add null value in not null attribute abstract

This works great in tables defined the same way in MySQL ...

I would think that cfqueryparam would be sending an empty string, not a 
null...

The simpler solution is just to allow null values in fields that are not 
required... but I tend to avoid null values as a general rule (I read 
somewhere that indices on not null fields are more efficient)

  - Rick

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Discover CFTicket - The leading ColdFusion Help Desk and Trouble 
Ticket application

http://www.houseoffusion.com/banners/view.cfm?bannerid=48

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:192562
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to