Re: problem in getting Large Object from pooled PostgreSQL / Tomcat 6

Поиск
Список
Период
Сортировка
От Dave Cramer
Тема Re: problem in getting Large Object from pooled PostgreSQL / Tomcat 6
Дата
Msg-id 491f66a50812230358j784bde0ft72f34413e06c6cc4@mail.gmail.com
обсуждение исходный текст
Ответ на Re: problem in getting Large Object from pooled PostgreSQL / Tomcat 6  ("Albe Laurenz" <laurenz.albe@wien.gv.at>)
Список pgsql-jdbc


On Tue, Dec 23, 2008 at 3:12 AM, Albe Laurenz <laurenz.albe@wien.gv.at> wrote:
ahmettemiz88 wrote:
> I am trying to Retrieve image ( Large Object) from pooled PostgreSQL /
> tomcat 6:
>
> I am having some exceptions from following
>
> ds = (DataSource) ctx.lookup("java:comp/env/jdbc/bzk2");
> Connection conn = ds.getConnection();
> PGConnection pgCon = (PGConnection) ((DelegatingConnection)conn) //
> ****exception
> .getInnermostDelegate();
>
> lobj = ((org.postgresql.PGConnection)pgCon).getLargeObjectAPI();
>
[...]
> org.apache.tomcat.dbcp.dbcp.PoolingDataSource
> $PoolGuardConnectionWrapper cannot be cast to
> org.apache.commons.dbcp.DelegatingConnection
>
>
> how can I solve the problem ?
You have to get the underlying connection from the pooled connection.

Dave

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

Предыдущее
От: "Albe Laurenz"
Дата:
Сообщение: Re: problem in getting Large Object from pooled PostgreSQL / Tomcat 6
Следующее
От: "ahmet temiz"
Дата:
Сообщение: what to do to display largeobject (image)