🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.database.ado
Article #344

E_FAIL with NOT NULL datetime

#344
From: crhras
Date: Fri, 18 Aug 2006 02:21
32 lines
1670 bytes
Can someone please explain why the following occurs ?

The first table gives E_FAIL whenever the table is opened and at least one 
record is "000-00-00 00:00:00".  The second table works just fine.  The 
second table is exactly the same as the first except DTime is declared as 
NOT NULL.

--
-- broken table
--
CREATE TABLE  tt (
  serial            int(10) unsigned NOT NULL auto_increment,
  DTime         datetime NOT NULL default '0000-00-00 00:00:00',
  val               int,
  PRIMARY KEY (serial)
)
;

--
-- good table
--
CREATE TABLE  tt (
  serial            int(10) unsigned NOT NULL auto_increment,
  DTime         datetime default '0000-00-00 00:00:00',
  val               int,
  PRIMARY KEY (serial)
)
;

Thank you,
Curt
Technical Details
Message-ID: <44e52431$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news2.google.com!news3.google.com!news2.google.com!news.maxwell.syr.edu!news.tele.dk!news.tele.dk!small.news.tele.dk!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Thread: 10698b,ab7fdf66c4df4ca4,start
X-Google-Attributes: gid10698b,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "crhras" <crhras@sbcglobal.net>
Newsgroups: borland.public.cppbuilder.database.ado
Subject: E_FAIL with NOT NULL datetime
Date: Thu, 17 Aug 2006 21:21:38 -0500
Lines: 34
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2869
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2962
X-RFC2646: Format=Flowed; Original
NNTP-Posting-Host: 75.34.174.119
Message-ID: <44e52431$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1155867697 75.34.174.119 (17 Aug 2006 19:21:37 -0700)
Path: arc1-ca.pugleaf.net!g2news2.google.com!news3.google.com!news2.google.com!news.maxwell.syr.edu!news.tele.dk!news.tele.dk!small.news.tele.dk!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail