Re: issuing insert preparedstatement queries with default values

Поиск
Список
Период
Сортировка
От Lew
Тема Re: issuing insert preparedstatement queries with default values
Дата
Msg-id hk2798$iq7$2@news.albasani.net
обсуждение исходный текст
Ответ на Re: issuing insert preparedstatement queries with default values  (Johnny Luong <johnny.luong@trustcommerce.com>)
Список pgsql-jdbc
Johnny Luong wrote:
> |> Is there a way to use the DEFAULT per column value on an INSERT sql in
> |> PG through the PreparedStatement JDBC API?  It'd be nice so that I don't
> |> have to maintain a secondary list of PreparedStatements or a list of
> |> default values maintained outside of the database definition.
...
> | TableEntryForm addUpdateTableEntry() Connection Created
> | INSERT INTO "public"."key_table4" ("avatar_id", "user_id", "bing_id")
> | VALUES (?, ?, default)
> | TableEntryForm addUpdateTableEntry() Connection Closed

I just leave out the columns in the INSERT for which I want default values.

--
Lew

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

Предыдущее
От: Oliver Jowett
Дата:
Сообщение: Re: driver initialization and connection separation
Следующее
От: Richard Troy
Дата:
Сообщение: Re: driver initialization and connection separation