Re: ERROR: Memory exhausted in AllocSetAlloc(909324558)

From: darcy(at)druid(dot)net (D'Arcy J(dot)M(dot) Cain)
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: ERROR: Memory exhausted in AllocSetAlloc(909324558)
Date: 2001-06-09 17:47:39
Message-ID: 20010609174739.A1F531A62@druid.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Thus spake Tom Lane
> darcy(at)druid(dot)net (D'Arcy J.M. Cain) writes:
> > char cardnum[48];
> > ...
> > newval = CStringGetDatum(cardnum);
>
> And you are trying to assign this datum to what kind of column?
> (Hint: there isn't any kind for which a plain C string is valid data.)

Right. That was just my latest try. I did notice that CStringGetDatum was
just defined as PointerGetDatum. I tried to find something specific for
text but nothing seemed to fit the bill. I saw DatumGetTextP but that
detoasts a toasted object. There were the various PG_RETURNxxx macros
but this is a user created strting, not an argument.

Do I have to manually create a varlena? I'll try that next.

--
D'Arcy J.M. Cain <darcy(at){druid|vex}.net> | Democracy is three wolves
http://www.druid.net/darcy/ | and a sheep voting on
+1 416 425 1212 (DoD#0082) (eNTP) | what's for dinner.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2001-06-09 18:36:50 Re: ERROR: Memory exhausted in AllocSetAlloc(909324558)
Previous Message Tom Lane 2001-06-09 16:59:58 Re: [JDBC] unlink large objects