Re: NULLs in ecpg

Поиск
Список
Период
Сортировка
От Edmund Bacon
Тема Re: NULLs in ecpg
Дата
Msg-id 40F804B7.2090101@onesystem.com
обсуждение исходный текст
Ответ на Re: NULLs in ecpg  (<wespvp@syntegra.com>)
Ответы Re: NULLs in ecpg  (<wespvp@syntegra.com>)
Список pgsql-interfaces
wespvp@syntegra.com wrote:
> On 7/16/04 11:11 AM, "Edmund Bacon" <ebacon@onesystem.com> wrote:
> 
> 
>>Indicators works as expected.  e.g.:
>>
>>EXEC SQL INSERT INTO sometable
>>        VALUES (:v1 :v1_ind, 'foo', :v2 :v2_ind);
> 
> 
> Hmm.  I tried that.  Just tried it again and it worked.  Must have had a
> typo before.  Sorry.
> 
> What about if I have something like:
> 
>  ... VALUES (TO_TIMESTAMP(:expirationDate, 'YYYYMMDDHH24MISS'), 'foo', :v2)
> 
> How can I insert NULLS for expirationDate when there's a function in the
> way?  Using
> 
>    ... VALUES (TO_TIMESTAMP(:expirationDate, 'YYYYMMDDHH24MISS') :ind1, ...
> 
> won't work.

No, but ... VALUES (TO_TIMESTAMP(:expirationDate :ind1, 'YYYYMMDDHH24MISS'), ..
should

-- 
Edmund Bacon <ebacon@onesystem.com>


В списке pgsql-interfaces по дате отправления:

Предыдущее
От:
Дата:
Сообщение: Re: NULLs in ecpg
Следующее
От: Darren G Pifer
Дата:
Сообщение: Make test problem