[Zope] setting null date in SQL

McDonnell, Larry lmcdonnell@protonenergy.com
Mon, 2 Jun 2003 10:05:45 -0400


Hi,

I can do this to an MS Access DB:

<dtml-if mea_creation_date><dtml-if "mea_creation_date==''">NULL<dtml-else>
 <dtml-sqlvar mea_creation_date
type=string></dtml-if><dtml-else>NULL</dtml-if>

-----Original Message-----
From: Kelley, Sean [mailto:SKelley@ci.santa-rosa.ca.us]
Sent: Friday, May 30, 2003 5:06 PM
To: 'zope@zope.org'
Subject: [Zope] setting null date in SQL


I cannot seem to set date to NULL in MS SQL with INSERT but it seems to work
on UPDATE with this code:
Insert sets date to 1/1/1900


<dtml-if "AppDelDate==''">
AppDelDate=NULL,
<dtml-else>
'<dtml-var name="AppDelDate" sql_quote>',
</dtml-if>


Trying this request to the group again since I have not found a solution.
Sean

_______________________________________________
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )