Re: Default and PQexecParams

From: ljb <ljb220(at)mindspring(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: Default and PQexecParams
Date: 2005-11-29 01:09:55
Message-ID: dmg9p3$28up$1@news.hub.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

jerry(dot)levan(at)eku(dot)edu wrote:
> Hi,
>
> How could one differentiate between DEFAULT and 'DEFAULT' as parameters
> to PQexecuteParams?

I assume you mean the libpq function PQexecParams(), and you want to use a
parameterized query for INSERT or UPDATE.

I don't think it is possible to use DEFAULT because it is a keyword,
and only a value expression will work as a parameter.

With NULL vs 'NULL', PQexecParams() has a special case to handle NULL
(null pointer in the paramValues array).

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2005-11-29 02:20:03 Re: Getting "cannot remove lock from HTAB" during VACUUM FULL
Previous Message Steve Crawford 2005-11-29 00:55:25 Re: Installation trouble