Return-Path: Delivered-To: apmail-db-derby-user-archive@www.apache.org Received: (qmail 87765 invoked from network); 13 Aug 2009 19:20:13 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 13 Aug 2009 19:20:13 -0000 Received: (qmail 59454 invoked by uid 500); 13 Aug 2009 19:20:20 -0000 Delivered-To: apmail-db-derby-user-archive@db.apache.org Received: (qmail 59388 invoked by uid 500); 13 Aug 2009 19:20:19 -0000 Mailing-List: contact derby-user-help@db.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: List-Id: Reply-To: "Derby Discussion" Delivered-To: mailing list derby-user@db.apache.org Received: (qmail 59380 invoked by uid 99); 13 Aug 2009 19:20:19 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 13 Aug 2009 19:20:19 +0000 X-ASF-Spam-Status: No, hits=2.2 required=10.0 tests=HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of francois.orsini@gmail.com designates 209.85.219.211 as permitted sender) Received: from [209.85.219.211] (HELO mail-ew0-f211.google.com) (209.85.219.211) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 13 Aug 2009 19:20:08 +0000 Received: by ewy7 with SMTP id 7so1011180ewy.7 for ; Thu, 13 Aug 2009 12:19:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type; bh=uZLGUBNP5rWkTSCHO1kuERm59C03F8aMA7fBDLe/aNU=; b=O8qCiwDLUdNxZaADj9pLC7vp5WOZot1jN1/keWe3emHB0QeAly7oNVjMgfqNl9qAMJ aP6z6gGZ3g8oT/Kr0IIGYaDxy0c6Pigoq928xztQYRTYFwSuslleVwyFwJMhNavrNp2c 3KcRyFSvyxsHK9JRR3IPB3oa9/yJWkzWxIVyY= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=HDaEKb1JHxnjJNuFLR40UZYVQRAVdnS1ZQqnxA6tzI+2z370jg4rUA0qVXlrjuVFhJ AawLLRjzwsY6MmAMAudPBcnNe4zSQoYtCqGogPCmQO8BLxADZookOXo6g0gM+vPymII7 cov6g+B38oipUJEU0zSV/mzQTfF0oAA/YcRo8= MIME-Version: 1.0 Received: by 10.216.11.212 with SMTP id 62mr231499wex.186.1250191188517; Thu, 13 Aug 2009 12:19:48 -0700 (PDT) In-Reply-To: <24954784.post@talk.nabble.com> References: <24954784.post@talk.nabble.com> Date: Thu, 13 Aug 2009 12:19:48 -0700 Message-ID: <7921d3e40908131219o263bb1a6xdf81a4512a354f7a@mail.gmail.com> Subject: Re: Unable to create derby datasource From: Francois Orsini To: Derby Discussion Content-Type: multipart/alternative; boundary=0016364d23ddb1671804710ad19c X-Virus-Checked: Checked by ClamAV on apache.org --0016364d23ddb1671804710ad19c Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Hi, Is 'derby.jar' referenced as part of the CLASSPATH for Spring? If not, then it cannot find the embedded Derby driver ('org.apache.derby.jdbc.EmbeddedDriver') required to connect to an embedded Derby instance. Cheers --francois On Thu, Aug 13, 2009 at 7:23 AM, nagl wrote: > > Hi, > > I am using spring framework to create datasource using xapool and jotm. > I want a configurable datasource for oracle and derby. > The following are the bean definitions I am using: > > [code] class="org.enhydra.jdbc.standard.StandardXADataSource" > destroy-method="shutdown"> > > > > > ${jdbc.ClassName} > > > > ${jdbc.org.URL} > > > > class="org.enhydra.jdbc.pool.StandardXAPoolDataSource" > destroy-method="shutdown"> > > > > > ${jdbc.org.user} > > > ${jdbc.org.password} > > > 30 > > [/code] > > Following are the properties I am using for derby datasource: > > [code] org.apache.derby.jdbc.EmbeddedDriver > jdbc:derby:target/derby/orgDB;create=true > org > org[/code] > > Now when i am passing oracle properties for the placeholders the datasource > is successfully created. > But when i switch to derby i get the following error. > > java.sql.SQLException: Cannot get connection for URL > jdbc:derby:target/derby/luDB;create=true > : No suitable driver found for > jdbc:derby:target/derby/luDB;create=true > > Now I am using Maven for dependencies and have made sure that derby is > included in the dependency and its also clearly visible in the dependency > graph in eclipse. > What else can be the issue. Please put in your suggestions. > > > > > > > -- > View this message in context: > http://www.nabble.com/Unable-to-create-derby-datasource-tp24954784p24954784.html > Sent from the Apache Derby Users mailing list archive at Nabble.com. > > --0016364d23ddb1671804710ad19c Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hi,

Is 'derby.jar' referenced as part of the CLASSPATH for S= pring?

If not, then it cannot find the embedded Derby driver ('o= rg.apache.derby.jdbc.EmbeddedDriver') required to connect to an embedde= d Derby instance.

Cheers

--francois

On Thu, Aug = 13, 2009 at 7:23 AM, nagl <neeravagl@gmail.com> wrote:

Hi,

I am using spring framework to create datasource using xapool and jotm.
I want a configurable datasource for oracle and derby.
The following are the bean definitions I am using:

[code]<bean id=3D"innerorgDataSource"
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0class=3D"org.enhydra.jdbc.standard.Sta= ndardXADataSource"
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0destroy-method=3D"shutdown"> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0<property name=3D"transactionManage= r">
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0<ref local=3D"jotm&= quot; />
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0</property>
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0<property name=3D"driverName"&= gt;
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0<value>${jdbc.ClassNa= me}</value>
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0</property>
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0<property name=3D"url">
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0<value>
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0${jdbc.org.= URL}
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0</value>
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0</property>
</bean>
<bean id=3D"orgDataSource"
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0class=3D"org.enhydra.jdbc.pool.Standar= dXAPoolDataSource"
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0destroy-method=3D"shutdown"> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0<property name=3D"dataSource"&= gt;
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0<ref local=3D"inner= orgDataSource" />
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0</property>
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0<property name=3D"user"> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0<value>${jdbc.org.use= r}</value>
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0</property>
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0<property name=3D"password">= ;
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0<value>${jdbc.org.pas= sword}</value>
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0</property>
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0<property name=3D"maxSize">=
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0<value>30</value&g= t;
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0</property>
=A0 =A0 =A0 =A0</bean>[/code]

Following are the properties I am using for derby datasource:

[code] =A0org.apache.derby.jdbc.EmbeddedDriver
=A0 =A0 =A0 =A0jdbc:derby:target/derby/orgDB;create=3Dtrue
=A0 =A0 =A0 =A0org
=A0 =A0 =A0 =A0org[/code]

Now when i am passing oracle properties for the placeholders the datasource=
is successfully created.
But when i switch to derby i get the following error.

java.sql.SQLException: Cannot get connection for URL
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0jdbc:derby:= target/derby/luDB;create=3Dtrue
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 : No suitable driver found= for
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0jdbc:derby:= target/derby/luDB;create=3Dtrue

Now I am using Maven for dependencies and have made sure that derby is
included in the dependency and its also clearly visible in the dependency graph in eclipse.
What else can be the issue. Please put in your suggestions.






--
View this message in context: http://ww= w.nabble.com/Unable-to-create-derby-datasource-tp24954784p24954784.html=
Sent from the Apache Derby Users mailing list archive at Nabble.com.


--0016364d23ddb1671804710ad19c--