| From: | Zeugswetter Andreas SB <ZeugswetterA(at)wien(dot)spardat(dot)at> |
|---|---|
| To: | "'Tim Perdue'" <tperdue(at)valinux(dot)com> |
| Cc: | pgsql-hackers(at)hub(dot)org |
| Subject: | AW: 7.0.2 issues / Geocrawler |
| Date: | 2000-07-12 17:18:44 |
| Message-ID: | 11C1E6749A55D411A9670001FA687963368007@sdexcsrv1.f000.d0188.sd.spardat.at |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
> Your ideas for selecting based on the date are intriguing, however the
> schema of the db was not done with that in mind. Everyone thinks I'm a
> nut when I say this, but the date is stored in a char(14) field in
> gregorian format: 19990101125959
Perfect, that makes it a lot easier:
1. index on (mail_list, mail_date)
2. SELECT mailid, mail_date, mail_is_followup, mail_from, mail_subject
FROM mail_archive WHERE mail_list=35
AND mail_date between '20000100' and '20000199'
ORDER BY mail_list DESC, mail_date DESC LIMIT 26 OFFSET 0;
Note the appended 00 and 99 which is generic for all months.
Andreas
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Tim Perdue | 2000-07-12 17:44:46 | Re: AW: 7.0.2 issues / Geocrawler |
| Previous Message | The Hermit Hacker | 2000-07-12 17:01:07 | Re: 7.0.2 issues / Geocrawler |