X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id C52A2528B1 for ; Wed, 8 Jun 2005 15:47:49 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 15759-07 for ; Wed, 8 Jun 2005 18:47:45 +0000 (GMT) Received: from mx1.redhat.com (mx1.redhat.com [66.187.233.31]) by svr1.postgresql.org (Postfix) with ESMTP id 319AB52883 for ; Wed, 8 Jun 2005 15:47:44 -0300 (ADT) Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254]) by mx1.redhat.com (8.12.11/8.12.11) with ESMTP id j58IlilO032266 for ; Wed, 8 Jun 2005 14:47:44 -0400 Received: from mail.boston.redhat.com (mail.boston.redhat.com [172.16.76.12]) by int-mx1.corp.redhat.com (8.11.6/8.11.6) with ESMTP id j58IliO07274 for ; Wed, 8 Jun 2005 14:47:44 -0400 Received: from vpn83-142.boston.redhat.com (vpn83-142.boston.redhat.com [172.16.83.142]) by mail.boston.redhat.com (8.12.8/8.12.8) with ESMTP id j58IliZP008959 for ; Wed, 8 Jun 2005 14:47:44 -0400 From: Vadim Nasardinov Organization: Red Hat / Westford To: pgsql-jdbc@postgresql.org Subject: Re: Jboss and largeObjectManager Date: Wed, 8 Jun 2005 14:51:38 -0400 User-Agent: KMail/1.7.1 References: <42A7372C.7000509@frojonck.dk> In-Reply-To: <42A7372C.7000509@frojonck.dk> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200506081451.38630@vadim.nasardinov> X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.015 tagged_above=0 required=5 tests=AWL X-Spam-Level: X-Archive-Number: 200506/41 X-Sequence-Number: 13003 On Wednesday 08 June 2005 14:21, torben wrote: > LargeObjectManager lobj = ((org.postgresql.PGConnection) dbcon).getLargeObjectAPI(); > > I get the error java.lang.ClassCastException: > org.jboss.resource.adapter.jdbc.WrappedConnection I'm not a JBoss programmer, but looking at the JBoss Javadoc at http://docs.jboss.org/jbossas/javadoc/4.0.2/org/jboss/resource/adapter/jdbc/WrappedConnection.html#getUnderlyingConnection%28%29 it seems to me that what you want to do is LargeObjectManager lobj = ((org.postgresql.PGConnection) dbcon.getUnderlyingConnection()).getLargeObjectAPI(); (As a side note, this question should've been directed to some JBoss-specific list.)