ecpg: arrays and nulls

From: Kuba Ouhrabka <kuba(at)comgate(dot)cz>
To: pgsql-interfaces(at)postgresql(dot)org
Subject: ecpg: arrays and nulls
Date: 2005-08-02 08:40:23
Message-ID: dcnbhr$13ed$1@news.hub.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-interfaces

Hi,

I'd like to ask how to handle null values when fetching arrays into
ecpg. Always I get this error:

Data read from backend is not an array in line ...

I'm using indicators and I use char * variables for array values (for
all column types: int[], text[], bytea[]). It works when the value of
array is not null but when it's null I get the error above.

Can null values in columns of array type be handled in more convenient
way than using coalesce/nullif and special reserved value?

Thanks, Kuba

Responses

Browse pgsql-interfaces by date

  From Date Subject
Next Message Jeff Eckermann 2005-08-03 00:25:40 Re: about postgres performance issue
Previous Message ljb 2005-08-01 02:21:13 Re: Problem With TCL