Thanks for reply,
I given the same which you given the example in mail, but I am getting the
same error.
Regards,
Srini
________________________________
From: Michael Dick [via OpenJPA]
[mailto:[email protected]]
Sent: Tuesday, February 09, 2010 7:23 PM
To: Srinivasulu.Kristnam
Subject: Re: While connecting MySql Server i am getting the Error For input
string: "JDBC"
Hi Srini,
You need to replace hostname , port, and myDataBase in with the appropriate
values for your database.
For example :
<property name="openjpa.ConnectionURL"
value="jdbc:sqlserver://localhost:1433;databaseName=testDatabase"/>
Regards,
-mike
On Tue, Feb 9, 2010 at 6:19 AM, SreeAsh <[hidden
email]<http://n2.nabble.com/user/SendEmail.jtp?type=node&node=4541141&i=0>
> wrote:
>
> Hi ,
>
> I am new to the JPA, I am using the MySql Server to OpenJPa, while
> connecting to the databse throwing the following error.
>
>
> <openjpa-1.2.0-r422266:683325 fatal user error>
> org.apache.openjpa.util.UserException: A connection could not be obtained
> for driver class "com.microsoft.sqlserver.jdbc.SQLServerDriver" and URL
> "jdbc:sqlserver://host\port;databaseName=MyDataBase". You may have
> specified an invalid URL.
> Error For input string: "JDBC" and in
>
> pelase see the persistence.xml file
>
> <persistence-unit name="TestJpaPU" transaction-type="RESOURCE_LOCAL">
>
> <provider>org.apache.openjpa.persistence.PersistenceProviderImpl</provider>
> <class>com.test.jpa.TblCustAddress</class>
> <class>com.test.jpa.TblCustContact</class>
> <class>com.test.jpa.TblCustomer</class>
> <properties>
> <property name="openjpa.ConnectionUserName" value="user"/>
> <property name="openjpa.ConnectionPassword" value="pass"/>
> <property name="openjpa.ConnectionURL"
> value="jdbc:sqlserver://host\port;databaseName=Mydatabase"/>
> <property name="openjpa.ConnectionDriverName"
> value="com.microsoft.sqlserver.jdbc.SQLServerDriver"/>
> </properties>
> </persistence-unit>
>
> please help me to fix this issue....
>
> regsrds
> Srini
> --
> View this message in context:
> http://n2.nabble.com/While-connecting-MySql-Server-i-am-getting-the-Error-For-input-string-JDBC-tp4540703p4540703.html
> Sent from the OpenJPA Developers mailing list archive at Nabble.com.
>
________________________________
View message @
http://n2.nabble.com/While-connecting-MySql-Server-i-am-getting-the-Error-For-input-string-JDBC-tp4540703p4541141.html
To unsubscribe from While connecting MySql Server i am getting the Error For
input string: "JDBC", click here< (link removed) =>.
________________________________
Information transmitted by this e-mail is proprietary to MphasiS, its
associated companies and/ or its customers and is intended for use only by the
individual or entity to which it is addressed, and may contain information that
is privileged, confidential or exempt from disclosure under applicable law. If
you are not the intended recipient or it appears that this mail has been
forwarded to you without proper authority, you are notified that any use or
dissemination of this information in any manner is strictly prohibited. In such
cases, please notify us immediately at [email protected] and delete
this mail from your records.
--
View this message in context:
http://n2.nabble.com/While-connecting-MySql-Server-i-am-getting-the-Error-For-input-string-JDBC-tp4540703p4545934.html
Sent from the OpenJPA Developers mailing list archive at Nabble.com.