Date storage class type - Mailing list pgsql-general

From Daryl Sayers
Subject Date storage class type
Date
Msg-id 200008110444.OAA14306@mippet.ci.com.au
Whole thread Raw
Responses Re: Date storage class type  (Radoslaw Stachowiak <radek@alter.pl>)
List pgsql-general
I sent this last night but I dont think it got through. Here it is again.
Sorry if its a duplicate.

-------------------------------------------------------------------------------
I think I have missed something obvious. I am writting my first postgresql
C program that accesses a table with a date field. I do the request using
a DECLARE BINARY CURSOR. I have a few floats/ints etc that I get
float *o;
int   *v;

o  = (float *)PQgetvalue(res, i, HIO);
v  = (float *)PQgetvalue(res, i, HIV);

My problem is I cant seem to get a date back into a usable form. How do
I retrieve a date back using a binary cursor. What storage type does it
use?


--
Daryl Sayers
Corinthian Engineering                         Ph: (02) 9906 7866
Suite 19, 401 Pacific Hwy                     Fax: (02) 9906 1556
Artarmon, NSW, 2064                         email: daryl@ci.com.au
Australia                                     www: http://www.cordoors.com.au

pgsql-general by date:

Previous
From: Matthew
Date:
Subject: RE: Windows 98
Next
From: Tom Lane
Date:
Subject: Re: Postgres problems with large databases.