🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.interbase.sql
Article #464

Re: Date matching for better performance.

#464
From: Bill Todd
Date: Sun, 25 Nov 2007 14:08
21 lines
1567 bytes
Monalee Bhandge wrote:

> 
> Dear,
>   I have one column trans_date of DATE type.How should I match
> trans_date column?  e.g If I want to match 01-April-2007 then
>     by which data retrive fast.
> 
>     WHERE trans_date='2007-04-01';
>      OR
>     WHERE trans_date='04-01-07';
>      OR
>     WHERE trans_date='04-01-2007';

It makes no performance difference which date format you use as long as
you use a format that InterBase understands. If you are running a query
from within a program it is best to use a parameter for the date to
avoid date format problems.

-- 
Bill Todd (TeamB)
Technical Details
Message-ID: <47498ffb$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!nx01.iad01.newshosting.com!newshosting.com!news.glorb.com!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail
References: <47493b3e$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 114a0e,1fb34ae6a20843ff
X-Google-Attributes: gid114a0e,public,usenet
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Bill Todd" <no@no.com>
Subject: Re: Date matching for better performance.
Newsgroups: borland.public.interbase.sql
References:  <47493b3e$1@newsgroups.borland.com>
Organization: The Database Group, Inc.
User-Agent: XanaNews/1.18.1.6
X-Face: ":yn4zt^A_dn>6~{YJmu^B\'4w)e:apPM\VC=Dvf&*tASxX9|BYczkFd$xr.$vNSZ[3Uobr p]c4\+\l){!WQI.$]veP({HLd;CDYH?iN
NNTP-Posting-Host: 65.118.176.23
Message-ID: <47498ffb$1@newsgroups.borland.com>
Date: 25 Nov 2007 07:08:43 -0700
X-Trace: newsgroups.borland.com 1196003323 65.118.176.23 (25 Nov 2007 07:08:43 -0700)
Lines: 21
X-Authenticated-User: btodd
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!nx01.iad01.newshosting.com!newshosting.com!news.glorb.com!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail