Re: Date help
| От | Garrett Murphy |
|---|---|
| Тема | Re: Date help |
| Дата | |
| Msg-id | 076DC33A3D38CE4BBC64D35DDD9DE70C0B13892F@mse4be2.mse4.exchange.ms обсуждение исходный текст |
| Ответ на | Date help (richard terry <rterry@pacific.net.au>) |
| Ответы |
Re: Date help
|
| Список | pgsql-novice |
> Hi List, > > This should be simple but though reading the doc's can't figure it out - I'm > hopeless at intrepreting documentation. > > I just want to extract from a table containing entries with dates, all entries > from within a specified interval eg last month, or last 10 days. > > Any help appreciated. > > Richard Your post isn't the clearest, but there are a few ways of accomplishing this. Probably the easiest is: ...WHERE date_field>=(CURRENT_DATE-INTERVAL '10 days') ...WHERE date_field>=(CURRENT_DATE-INTERVAL '1 month') And so on.
В списке pgsql-novice по дате отправления: