getting at the actual int4 value of an abstime - Mailing list pgsql-hackers

From jim@reptiles.org (Jim Mercer)
Subject getting at the actual int4 value of an abstime
Date
Msg-id m11Grdh-00080YC@mailbox.reptiles.org
Whole thread Raw
Responses Re: [HACKERS] getting at the actual int4 value of an abstime
List pgsql-hackers
i have a table which uses an abstime to store a time/date.

the data originates as unix time_t, which i convert to a string when inserting
the data into the table.

i do select's from the table with WHERE clauses that use the abstime stuff.

i want to get the results of a select as unix time_t, without having to use
the expensive mktime()/strptime() unix C calls.

is there a way to get the int4 value that postgres is storing raw for
abstime?

i'm working in C with libpq.

--
[ Jim Mercer    Reptilian Research      jim@reptiles.org   +1 416 410-5633 ]
[ The telephone, for those of you who  have forgotten, was a commonly used ]
[ communications technology in the days before electronic mail.            ]
[ They're still easy to find in most large cities. -- Nathaniel Borenstein ]

pgsql-hackers by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: [HACKERS] "out of free buffers: time to abort" message?
Next
From: "Ross J. Reedstrom"
Date:
Subject: Re: [HACKERS] getting at the actual int4 value of an abstime