Date/Time atributes and binary cursors

Поиск
Список
Период
Сортировка
От Gonçalo Marrafa
Тема Date/Time atributes and binary cursors
Дата
Msg-id 20040402155110.14a956a1.gjm@uevora.pt
обсуждение исходный текст
Ответы Re: Date/Time atributes and binary cursors
Список pgsql-interfaces
Hi there.

I'm trying to read a timestamp without timezone attribute, using binary cursors. I can read the data but i don't know
whatto do with it. I would like to convert it to a time_t or tm struct. How can i do this? 

I'm using postgresql 7.4 on Debian sid.

Here's a snippet of the code i'm using:

...
#include <postgresql/pgtypes_timestamp.h>
...
timestamp *ts; ts = (timestamp *) PQgetvalue(res, i, f_num);


I would like to use date attributes too.

Thanks in advance.

--
Gonçalo Marrafa <gjm@uevora.pt>

В списке pgsql-interfaces по дате отправления:

Предыдущее
От: Adriaan Joubert
Дата:
Сообщение: Bug in translation of DEALLOCATE PREPARE
Следующее
От: Mikhail Ts
Дата:
Сообщение: PostgreSQL 7.4.2 libpq problem