0
votes
3answers
67 views

one base executeQuery method or one for every query

I've started creating a toDoList and I like to create a "DataMapper" to fire queries to my Database. I created this Datamapper to handle things for me but I don't know if my way of thinking is ...
0
votes
3answers
2k views

connection to mysql server failed

x1.instance3650.db.xeround.com-nino_db [chatserver.sql.MySqlConnection.rehash()] this is con null [.()] connection to MySQL server failed ...
2
votes
2answers
146 views

Can not connect multiple times to mysql

I am writing an own databse in scala. To verify my results are correct, I check with a MySQL inside of a specs2 specification. I get the right result and everything is just fine. But if I run the test ...
1
vote
2answers
176 views

Data Connection Dialog for Java

In .NET there are Data Connection Dialog UI which allows users to build connection strings and connect to specific data sources. Is there similar thing for java?
0
votes
2answers
51 views

MySQL Server terminated and hibernate database connection not closing

I have used the following code to create database connection using Hibernate configuration file. <property name="connection.driver_class">com.mysql.jdbc.Driver</property> <property ...
0
votes
2answers
2k views

Establishing connection from java to access 2010 64bit

After going through several tutorials and blog posts, i have unsuccessfully tried to set up a connection from java to a microsoft access database. my system specifications are win 7 [64 bit] ...
3
votes
1answer
1k views

com.mysql.jdbc.exceptions.MySQLSyntaxErrorException exception in CentOS server

Running a java code in CentOS server to connect mysql My code is - String server = "", url = "", password = "", user = "", databasename = ""; Connection con = null; try { server = ...
2
votes
1answer
61 views

using jdbc to query two databases to the same instance of sql server

In a Java standalone client server application (using Netbeans) I use a static method to connect to SQL server : but if I use the second connection I am getting the error : Exception in thread ...
2
votes
1answer
76 views

Almost 12 seconds delay in getting the connection from a remote database on a network

I have a Java Swing application which access a remote database on a local network. The code i used is as follow: Class.forName("org.apache.derby.jdbc.ClientDriver"); ...
2
votes
1answer
104 views

Issue with DB pool

I am using DB pool (DB Pool) in my application. My DAO code is like: static { try { PropertyUtil propertyUtil = new PropertyUtil(); ...
2
votes
1answer
650 views

establishing mysql/java/jdbc connection in runtime eclipse applications

i am making a swing based desktop application that is initiated through a menu command in a runtime esclipe application. let me define the flow... aC = main eclipse application project that ...
2
votes
1answer
1k views

How to extend c3p0 ComboPooledDataSource

Ok I have a resource in Tomcat 5.5 in server.xml for database connection like this: <Resource name="jdbc/MyApp" auth="Container" type="com.mchange.v2.c3p0.ComboPooledDataSource" ...
1
vote
1answer
40 views

Cannot connect to Oracle using SID

I m having web application where i connect with oracle with spring my application is not working if i give SID in xml file xml file entry is <bean id="dataSource" ...
1
vote
1answer
44 views

Is there a method to get the Total JDBC connections?

I have a jabber bot that connects to a database to gather data and report it. In case a connection goes down it is re-established and DB connection is re-initiated. Is there a method that I can call ...
1
vote
1answer
149 views

Tarantool Java Connector

Do you know a way to connect Java and the Tarantool key/value storage? On the Tarantool web-site I can see connectors for C, Ruby, PHP, etc., but no connector for Java. I know that Tarantool supports ...
1
vote
1answer
711 views

access 2010 connection with java

i have written a class [as shown by most tutorials] to make connection to an Access 2010 database package dataBase; import java.sql.Connection; import java.sql.DriverManager; import ...
1
vote
1answer
515 views

c3p0's max number of connections doesn't work in Linux

I have a java application that uses hibernate for O/R mapping and I also use c3p0 connection pooling that ships together with hibernate. The DB is Oracle. This is in my hibernate.cfg.xml: ...
0
votes
1answer
332 views

com.microsoft.sqlserver.jdbc.SQLServerException: The connection string contains a badly formed name or value

And my code is: try{ Class.forName("com.microsoft.sqlserver.jdbc.SQLServerDriver"); Connection ...
0
votes
1answer
101 views

com.mysql.jdbc.PacketTooBigException when just connecting the database

Im trying to connect to my sql database with the following command in java connection = DriverManager.getConnection(url, user, pass); where url is ...
0
votes
1answer
30 views

On DBConnections reuse

Today: I continue to work on an application, which, constantly creates and closes a LOT of (sql) connections to the same (Oracle) database, using the same credentials running very basic selects, ...
0
votes
1answer
1k views

Could not load the resource factory class java.lang.ClassNotFoundException: com.jolbox.bonecp.BoneCPDataSource

I want to do connection pooling using BoneCP. But i got a log of Could not load the resource factory class. I got a this error log on tomcat startup SEVERE: Exception processing Global JNDI Resources ...
0
votes
1answer
2k views

how to write connection string (url) in eclipse for jtds to connect to Sql server 2008R2

I am new to eclipse.Can anybody help? how to write connection string (url) in eclipse for jtds to connect to Sql server 2008R2 ?
0
votes
1answer
2k views

database connection not working in jar, but does work in eclipse

I have created a simple database in MYSQL, which I am trying to pull data from in a java program written in Eclipse. When I run the program in eclipse, it pulls out the data fine, but when I export ...
0
votes
1answer
76 views

my java socket application

I tried to make a simple port scanning programs from java and I make it like this: package PortScanning; /** * * @author fonts */ import java.net.*; import java.io.*; public class port { ...
0
votes
1answer
255 views

DB connection from Sun webserver

Hi whats the difference between the database connection made from a stand alone code and that made from a web application deployed in sun java web server. The code used to connect to the database, ...
-1
votes
1answer
52 views

phpmyadmin with java. Is there a way to get the strings from phpmyadmin and compare it with the input from the keyboard?

What I want to do is compare each word in the phpmyadmin database (columns and rows) with the user input from the keyboard. I know I can do this with a CSV file with equalsIgnoreCase. But I can't seem ...
-1
votes
1answer
313 views

In-use connections equal max-pool-size and expired max-wait-time. Cannot allocate more connections

I am facing following problem : HTTP Status 500 - type Exception report message descriptionThe server encountered an internal error () that prevented it from fulfilling this request. exception ...
-2
votes
1answer
869 views

You can't operate on a closed Connection

java.sql.SQLException: You can't operate on a closed Connection!!! at com.mchange.v2.sql.SqlUtils.toSQLException(SqlUtils.java:106) at com.mchange.v2.sql.SqlUtils.toSQLException(SqlUtils.java:65) ...
2
votes
0answers
77 views

What to do if database connection check fails in bootstrap?

I am developing an app using grails. In the bootstrap part, I am checking and initialising database connections. Suppose the database is not available due to some problem its wise to send notification ...
1
vote
0answers
274 views

ReasonCode=54. ERRORCODE=-4499, SQLSTATE=08001

I am getting following error message, A communication error occurred during operations on the connection's underlying socket, socket input stream, or socket output stream. Error location: ...
1
vote
0answers
142 views

Reconfigure Tomcat database connections at runtime

I'm working on a legacy Java web application that is deployed in a Tomcat container and accesses several databases from different vendors (Oracle, MS SQL, DB2). Currently the connections are ...
1
vote
0answers
714 views

ClassNotFound Exception while Calling through JAVA Web Service?

i have java class in which i have done database connection for SQL server and trying to retrieve data from table its working fine. but now i created web service in java for that class then its showing ...
0
votes
0answers
46 views

Two connections at the same time to a single sqlite database

I am using a connection to a SQLite database using Java. The problem is when the database is running in its application, my connection is stopped until the database is deactivated. How do I get my ...
0
votes
0answers
25 views

Sqlite database connection is closing on me

I have a database adapter in my web service that when created, opens a connection to a Sqlite database: public DatabaseAdapterJava(Database database) { try { ...
0
votes
0answers
93 views

SQL state [null]; error code [0]; DSRA9110E: Connection is closed

The below query runs fine in one environment but gives following error in another environment: SQL state [null]; error code [0]; DSRA9110E: Connection is closed. Nested exception is ...
0
votes
0answers
37 views

How to make my databaseconnect class to allow for concurrent use

I have create a class called databaseconnect which is responsible for: connecting to database, method for filling combobox, method for authentification, method for insert, remove, modify,.... The ...
0
votes
0answers
104 views

SingleConnectionDataSource connection closed after about 40 minutes inactivity

We have a problem with org.springframework.jdbc.datasource.SingleConnectionDataSource? We expect that the connection is never closed while the application is running, even if there is no traffic ...
0
votes
0answers
74 views

PacketTooBigException max_allowed_packet is right

When I try to do a query to my remote database I get this error: com.mysql.jdbc.PacketTooBigException: Packet for query is too large (4739923 > 1048576). You can change this value on the server ...
0
votes
0answers
79 views

A controller which gets data by Hibernate (using DAO)only works first time, called from its following jsp , but always works from precedent JSP

here is the problem. looking to the flow, the first JSP page has this link to the controller <a href="doctorgetPatients"> Returning Patient</a> then the following controller ...
0
votes
0answers
255 views

Derby database: Adding information to database within Java code

So I have this GUI and need to connect it to a derby database. The GUI has a menubar with menuitem Data>Employee>Add Employee for adding employee information into the database. When you click on Add ...
0
votes
0answers
551 views

javax.naming.NamingException: Cannot create resource instance issue

While running this sample code in eclipse (the issue is not related to JSF though) i get the error javax.naming.NamingException: Cannot create resource instance Java file import ...
0
votes
0answers
379 views

Export a Crystal Report in java - no db connection found

i want make a PDF Crystal Report with java. It works for a simple example. But if start my Report i get a Error. com.crystaldecisions.sdk.occa.report.lib.ReportSDKException: Fehler bei der Suche ...
0
votes
0answers
100 views

Confused on Derby Client Server

With reference to Libraries provided by Derby, I am confused about connecting my Java application, which needs a connection to a server database (Derby/Java DB on NetBeans). In particular, I am ...
0
votes
0answers
673 views

NoInitialContextException

I have a problem. I want to connect to database using JDBC, I have Tomcat server. For this I use connection pool. According to Internet tutorials I've written: context.xml: <?xml version="1.0" ...
0
votes
0answers
107 views

How to change custom properties in J2C Connection Factory under WebSphere in java program?

I'm trying to connect to IMS database via WebSphere. Currently I've a situation wherein I want one of the properties values to be dynamic instead of static values set in WebSphere. There's a property ...
0
votes
0answers
236 views

send data from java client application to database server java

Im developing a java application to automate an election process. Voters manually vote on a ballot paper and it is scanned in provincial counting centers. Then I want to send the data from provincial ...
0
votes
0answers
184 views

Relative path to MS Access-database

I've designed a small project for college using Access for data base and Java EE. The application works perfectly on a local machine using Apache Tomcat. I tried placing the database file on the ...
0
votes
0answers
306 views

code for search button(jbutton8)

first image shows the table in mysql. second image shows design of our search criteria in netabeans the third image is the of the coding of jbutton8 fourth is of the error we got. so for just checking ...
0
votes
0answers
623 views

JDBC SQLException for SQL Server

I have this piece of code which works well on DB2 and Oracle, but fails on MSSQL(both 2005 and 2008). c = SessionMgr.getInstance().getTOPLinkManager().getDataSource().getConnection(); String sql = ...