Re: statement caching proof of concept

Поиск
Список
Период
Сортировка
От till toenges
Тема Re: statement caching proof of concept
Дата
Msg-id 449739C7.2070303@kyon.de
обсуждение исходный текст
Ответ на Re: statement caching proof of concept  (Dave Cramer <pg@fastcrypt.com>)
Ответы Re: statement caching proof of concept  (Dave Cramer <pg@fastcrypt.com>)
Список pgsql-jdbc
Dave Cramer wrote:
> AFAIK Postgres doesn't allow concurrent statements on the same
> connection, so I don't see how using multiple threads would work ?

The statements wouldn't need to be concurrent in the sense of happening
at the same time:

// stupid query
String sql = "SELECT * FROM quicklychangingtable";
PreparedStatement p1 = connection.prepareStatement(sql);
PreparedStatement p2 = connection.prepareStatement(sql);
ResultSet r1 = p1.executeQuery();
// do something else for a while
ResultSet r2 = p2.executeQuery();

What happens with r1? Might be ok, but i'm not sure if this is always true.


Till

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

Предыдущее
От: Mark Lewis
Дата:
Сообщение: Re: statement caching proof of concept
Следующее
От: Dave Cramer
Дата:
Сообщение: Re: statement caching proof of concept