I've a table created like:
CREATE TABLE tbl_test
(
id bigserial PRIMARY KEY,
interest int ARRAY[2]
);
I got PGresult* res using PQexec(conn, "SELECT * FROM tbl_test");
Now, how can I get int[] from PQgetvalue(res, 0, 1).
I don't want to depend on structs defined in array.h as they might change.
I could not find any API in Postgresql docs which can do things.
Please advise.
Regards,
Mayank