FairCom Corporation
 
FairCom Start PageFairCom ProductsDownloadsDeveloper SupportSales InformationFairCom CustomersFairCom Company InformationContact FairCom

Homebulletgrey.gifeNewsletterbulletgrey.gifVolume 22bulletgrey.gifc- treeSQL Date Types


Differences With c- treeSQL Date Types

The following query on a table containing a Date field can return unexpected rows:

SELECT * FROM myTable WHERE myDate >= '0001-01-01' AND myDate <= '9999-01-01'

However, this query returns the expected set of rows.

SELECT * FROM myTable WHERE myDate >= '1700-03-01' AND myDate <= '9999-01-01'

Why the difference? The c-tree Plus Date field type stores dates as an unsigned four byte integer representing the number of days since 02/28/1700. Hence the first valid date is 03/01/1700. Date values before this date can result in unexpected results. Thus, when performing c-treeSQL queries on date data, keep in mind the c-tree Plus 2/28/1700 epoch starting value.

“We reviewed every database option available on the market today. Only FairCom could meet the real-time and throughput requirements we had to deliver in the TeaLeaf Web application management solution.”

Tim Knudsen
Director of Product Management,
TeaLeaf Technology

FairCom Start PageSite MapContact FairComThe FairCom Privacy Policy Your Location: USA | Europe | Brazil | Japan
Copyright 2010 FairCom Corporation. All rights reserved.