| От | Steve Crawford |
|---|---|
| Тема | Re: Date math question |
| Дата | |
| Msg-id | 492DCCFE.1060206@pinpointresearch.com обсуждение исходный текст |
| Ответ на | Date math question (Kevin Kempter <kevink@consistentstate.com>) |
| Список | pgsql-general |
Kevin Kempter wrote: > Hi All; > > I have a table that contains 2 columns ts (a timestamp) and dursec (a float - > number of seconds) > > I want to insert the following into another table: > > the ts (timestamp column) and a second date which is ts + dursec > > I tried these select variations with no luck: > > select ts, ts + interval dursec seconds from tmp2 limit 1; > > select ts, ts + 'seconds' dursec from tmp2 limit 1; > > > > Anyone know the correct syntax for this ? > Try ts + dursec * '1 second'::interval Cheers, Steve
В списке pgsql-general по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера