no of rows selected

138 byte By anithi78 at 2007-9-26 3:14:30
When I execute a "select" statement, I want to know how many rows it fetches from the database.How do I do it?

JTA problems with Oracle 8.1.6 - XAResource.start() throws an XAException.

1433 byte By diarmaid at 2007-9-26 3:14:51
Hi all.This issue is regarding the use of the JTA with Oracle. I discoveredthere was a lack of support for JTA in Oracle 8.1.5 and then foundthat their documentation now claims that JTA is supported in 8.1.6 andabove.I have written my own implementations of Transaction,TransactionManager, Xid, ...

Accessing database Variables using JDBC

600 byte By neelmukherjee at 2007-9-26 3:17:11
Hi, I have a question for some of you Java specialists out there. I want to execute a select statment in my database (SQL Server 2000) and store the output in a variable. - The reason I am not directly executing the SQL statement from my JDBC connection is that I need to execute a number of SQL ...

very large database

225 byte By ConlonP at 2007-9-26 3:17:14
I'm currently writing a program to interface with a 200MB database. The program has to connect to just a file, no server can be involved. Is there a JDBC driver to connect to an access file? just the .mdb file.

Usingthe next() method of Resultset to access Data from Database suing JDBC

827 byte By neelmukherjee at 2007-9-26 3:17:27
You know we use the next() method to read the rows from the result set after we execute our query using JDBC. What I found was that when I execute next(), the first row is fetched and stored in the resultset variable you define. I want to know if there is a way to putthe data back and when I do ...

SQLException 'general error' when using the JDBC-ODBC bridge

2560 byte By rajbhaskar at 2007-9-26 3:18:14
Hi folks,There's a guy in my department who's trying to get to grips with JSPs and JDBC. He's written a test JSP accessing an Access database via the JDBC-ODBC bridge, but when he tries to run it, he gets an SQLException with the not very helpful error "general error".The basic code is ...

Using a form to submit data to database

888 byte By dUb at 2007-9-26 3:18:32
I have a servlet and I am trying to implement a form in the page so that it will submit from a text box a string into the database. Here is my code.java.util.Date d = new java.util.Date();java.sql.Timestamp t = new java.sql.Timestamp(d.getTime());String data = "";out.println("<form ...

SQL Syntax Question

336 byte By bweemaster at 2007-9-26 3:18:33
I have an Access D-base thats of arbitary length.I need to know the number of rows in a table named Datelist.I could do a generic counter using the .next method but figure there is a much easier way.Each row will be read into an array ... thats why I need the length.Thanks in advance.B~ ...

Update the latest record

238 byte By billy.chen at 2007-9-26 3:19:06
How to update the latest record?for instance:UPDATE ATABEL SET STATUS='TRUE' WHERE EVENTID='IEOE93' AND TIME= try to find the latest record to update anyone can kindly help? thanks

Urgent......Rs.next() returns true pls help.

577 byte By gpadmaja at 2007-9-26 3:20:04
I am creating statement like this:myStmt1=con.createStatement(ResultSet.TYPE_SCROLL_INSENSITIVE,ResultSet.CONCUR_READ_ONLY);dbRs1 = myStmt1.executeQuery(sql);sql (select query) is returning zero rows if executed in query analyzer.but in my code if I check if(rs.next()) it is returning true even ...

SERVLET - ORACLE - NETWARE

4768 byte By nicolas9 at 2007-9-26 3:21:04
Hello everybody,Sorry for my english but i'm french.I try to make a servlet with a post method in which a request to the database is made.Here are the servlet, the html and the error returned : SERVLETimport java.io.*;import javax.servlet.*;import javax.servlet.http.*;import java.util.*;import ...

Limit to number of parameters in JDBC Prepared Statement

358 byte By jzaskar at 2007-9-26 3:21:13
There appears to be a limit to the number of parameters you can pass into a prepared statement.If I try and define more than 54, i get an error of "The number of parameter values set or registered does not match the number of parameters." ... even though they clearly do.Has anyone else ...

Java database connectivity

1279 byte By Mussarat at 2007-9-26 3:21:22
i have connected ms Access database in java application it is working fine but when i converted it into applet it is not detecting database. the necessary code is imsah is the name of the database and employees is the name of table in which there are two variables fname and lname. problem is ...

JDBC2ODBC & SqlServer

589 byte By Kamandi at 2007-9-26 3:22:28
Hi All,I have used sun jdbc2odbc for connecting to SqlServr database,But I have some problem with it.When i use resultset for reteiving data from one table,that table will be locked and i cant use another resultset for retreiving data from that table simultancely,in other word I cant use ...

Date Comparision

212 byte By satishs at 2007-9-26 3:22:58
I am using JSP and Access97. I need to compare the java.sql.Date type with the Date/Time in the Database. How can I run a query to find the dates after a particular date or before a particular date.

ResultSet problem

411 byte By moola_uma@hotmail.com at 2007-9-26 3:25:11
I am trying to insert one table data to another table. But if the second table is empty it is giving a runtime error that "before start of resultset". How to rectify that? In my condition I gave to insert into the table if first table id is not equal to second table id and if the count(*) is ...

Keeping " character from table column?

156 byte By CHEERS at 2007-9-26 3:25:45
Does anyone know of a way in which I can prevent the character " from being in any of the columns within my database table?Please help?

No suitable driver(VisualAge-DB2)

282 byte By jaquest at 2007-9-26 3:27:38
I get "java.sql.SQLException No suitable driver" when trying to import a schema from a DB2 (V.5.2) database(VisualAge for Java Enterprise. 3.5 for Win). Before I added the zip file with DB2 drivers to the Workspace classpath. How I can fix it?Thanks in advance.

[IBM][JDBC Driver] CLI0616E Error opening socket. SQLSTATE=08S01

581 byte By billjaguar at 2007-9-26 3:27:44
Hello all,I followed all instructions for setting up the driver and url. However, I still got the error message as the subject. My case is that:The ejb which tries to connect to a database run on one machine, while the database is on another. I copied runtime.zip, db2java.zip, sqlj.zip and ...

how to use backup for mysql database

104 byte By amnonm at 2007-9-26 3:28:51
I am using mysql am I want to backup my data.what is mysql propriate way to do it ?

problem in stmt.executeUpdate

230 byte By sasus at 2007-9-26 3:29:08
hi all, I am facing a NullPointerException when executing:stmt.executeUpdate("INSERT INTO PEOPLE (PRI,LOGIN_TYPE) VALUES ('21','2004')");in my code.any suggestion please.

Package oracle.sql not found

107 byte By amtanoli at 2007-9-26 3:30:06
i am using the driver classes111.zip, how can i find the package oracle.sql?amt

Problem with batch update

844 byte By sandrinep at 2007-9-26 3:30:44
Hi,I have the following problem: When I try to insert values to a db2 table with a batch update, something goes wrong during preparedStatement.executeBatch(), the follow Exception is thrown: java.lang.UnsatisfiedLinkError: SQLBindStringArray at ...

Problem in calling nested stored procedure

590 byte By Subhenduc at 2007-9-26 3:31:18
Hi,I am using execute(), getMoreResults() and getResultSet() methods to call sybase stored proc. It is working fine when calling a simple stored proc. But it is giving following error when this stored proc calls another stored proc inside it.<<Error connecting: ...

problems with jdbc and oracle

2727 byte By bsnlrt at 2007-9-26 3:31:36
I'm trying to execute this query with jdbc on oracle:INSERT INTO BFD_SHOP (ID_SHOP_TYPE,REGION_NAME_EXT,ID_SHOP_EXT,DATE_EXT,SHOP_NAME,ZONE,ADDRESS,PHONE_NUMBER,ID_REGION, EMAIL, LOOK, LOOKIMAGE,SPECIALITY, PRICE, NOTES, LABEL, LABEL_IMAGE, WAP_DESCRIPTION,WEB_DESCRIPTION, LOCALITY, LOOKNAME, ...

URGENT HELP

316 byte By geetuR at 2007-9-26 3:31:53
Hi I am working on a project that uses SQL Server 2000 as backend. Just today, when I tried to open the Enterprise Manager of SQL server, it gives me an error "MMC console cannot find the selected file"I have restarted the comp, reinstalled SQL server...but no luck!!HELP PLEASE!!! ...

Handling nulls in Java

165 byte By neelmukherjee at 2007-9-26 3:34:11
Is there a way we can convert a null string that we get from a Database to maybe something like a space.Please let me know urgentlythanks

JDBC 2.0 Connection Pooling Implementation

839 byte By kttan at 2007-9-26 3:35:00
Hi JDBC Experts,Since I didn't get the answer for my previous question, I am giving more Duke Dollars to whoever gives the best answer :)(Too bad I was given 25 dd, otherwise I will give you more...)I searched the books all over the book stores but none really shows the sample code that ...

Urgent: How to handle null from ResultSet

1136 byte By stressball at 2007-9-26 3:35:08
I am getting data from a ResultSet and putting it into a Hashtable. My problem is that some of the fields I am getting back are null, but I still need them. I would like to change them to an empty String, currently I am doing this but I would like to create a method to test if there is a null ...

Getting size of ResultSet Object

159 byte By firoux at 2007-9-26 3:35:19
Is there any effective way to retrieve the size of ResultSet object while the type of the ResultSet itself is a default one (TYPE_FORWARD_ONLY) ?

Compatibility old and new JDBC

268 byte By ka7ext at 2007-9-26 3:37:29
Has anyone had problems with compatibility between older and newer versions of JDBC? It seems to be automatically changing int into smallint and otherwise causing various random problems. Our problem is that we developed in 1.3 but we must now use 1.1.8.

Exception in thread "main" java.lang.UnsatisfiedLinkError: SQLBindStringArr

4965 byte By mgandham at 2007-9-26 3:37:57
I am unable to run executeBatch() in DB2, Error stack traceException in thread "main" java.lang.UnsatisfiedLinkError: SQLBindStringArrayat COM.ibm.db2.jdbc.app.DB2PreparedStatement.SQLBindStringArray(Native Method)at ...

Special language signs

1622 byte By jannypaddy at 2007-9-26 3:38:10
Hi!I have a application that mangages adresses. The adresses are stored in a MS Access database. All columns are "Text" (VARCHAR(50)). I use the "sun.jdbc.odbc.JdbcOdbcDriver" to connect to the Database. Now the Problem: I had to instert special language signs (German) like ? ? ?. I use the ...

"universal" jdbc

392 byte By tda at 2007-9-26 3:38:51
Hi ALL!Can anybody tell me. Does exist in nature an JDBC driver that can connect and do interactions to any database (oracle, informix etc.) or may be subset of them?That is I want to fulfil sql92 ( or may be other dialect ) compliant expressions through JDBC and jdbc driver will convert its ...

Get methods for MS SQL

288 byte By smitaunni at 2007-9-26 3:38:58
In my jsp if I useResultSet rs.getObject(1)it gives me null...But if I specify...it as getInt or getString etc...it works fine...Can anybody help...meI need to usegetObject...as I am string the full resultset in an arraysmita

java.sql.Date comparison with Oracle date

1063 byte By dilippr at 2007-9-26 3:39:21
Hi,I have converted string to java.sql.Date format after parsing using the below code . String testd="10/22/1997";SimpleDateFormat sdfinDate = new SimpleDateFormat("MM/dd/yyyy");java.util.Date actualDate = null;java.sql.Date asql = null;try{actualDate = sdfinDate.parse(testd);asql = new ...

A great help required...for a jdbc driver..free one

339 byte By smitaunni at 2007-9-26 3:39:24
I wanted to download..freetds...But I so very confused...the ftp shows many zip and jar files...So which should I download and where...Also what else do I require to make it work..I am using Jrun ...and my database is MS SQL Server 2000 and JDK 1.3.0_02.Pl..its very urgent...Pl help..smita ...

Oracle Connection Pooling

775 byte By jericd at 2007-9-26 3:39:52
Does anyone have any sample code for an Oracle connection pool using the thin driver? I've created my own connection pool that does not use Oracle's provided methods, and it works but I have a couple of concerns.Oracle connections cost, so I want to limit the number of connections in the pool ...

getting date value from MS SQL Server 2000

177 byte By marcalena at 2007-9-26 3:40:43
Hi,Can anyone show me how to get date value from MS SQL Server 2000? Or i need to create a Date class and use setTime() method to do so.Thanks for any help.

HELP-Resultset method: getString w/ LONGVARCHAR

2148 byte By ham17151 at 2007-9-26 3:41:59
Hello Everyone. When I use the getString method of a ResultSet class on a LONGVARCHAR data type, I get unexpected results. For instance, If the column contains a long text with several words (LONGVARCHAR data type), the getString method generates a string for each word in that column! ...

Help!! Cannot use updatable resultset with MS access

5820 byte By gamerfong at 2007-9-26 3:42:03
As above, I am trying to do a change password program which access a MS access database. I wanted to use the more convenient updatable result set which i heard from my friend which is better than sql statement to update the database. But it returns a exception to me. Does access support ...

JDBC2.0 Features in JDK1.3...HELP?

239 byte By soojee2 at 2007-9-26 3:42:12
Hi allI got jdk1.3 and im trying JDBC2.0 Features, but i count succeed. Im using the Driver given by SUN. rs.last() is not working...any thing else should be done...Need ur help in this.Thanks in advance.

jdbc Applet -Access connection

244 byte By Mussarat at 2007-9-26 3:42:31
i have connected a jdbc application with Access it is working fine but when i converted it into Applet it is giving me an error of SQLException and message is " No suitable driver "any one can help me?Mussarat

setRollBack method

841 byte By venkyp02 at 2007-9-26 3:42:53
I am using container managed persistence session bean to insert records in 3 different tables & i want to use setRollBack() method.My requirement is if any one fails to create a record , i should rollback the other records which are created .create()..... create().... create() if all the 3 ...

no suitable driver

452 byte By probirsil at 2007-9-26 3:43:52
I am getting no suitable driver error from the servlet although the driver jar file is in the classpath. This is happening in Solaris. I tried to connect to a MS SQL server with JTrubo driver. I can see few other people got the error before. Does anyone know the solution? I tried by registering ...

HELP!!! How to handle > 255 characters

347 byte By ham17151 at 2007-9-26 3:44:15
Help me PLEASE. I'm having trouble with a column that has a data type of LONGVARCHAR. For instance, if a column value contains more than 255 characters, then if I've been using the getString or getObject, they both create individual Strings or Objects for each word that appear beyond 255 ...

JDBC_ODBC connection through servet

3838 byte By samreengul at 2007-9-26 3:45:00
hi i want to know y this programme is having problem with Querying the Data base import javax.servlet.*;import javax.servlet.http.*;import java.io.*;import java.sql.*;//import ap.servlets.*;public class qry_movie extends HttpServlet { Connection dbcon; public void init() throws ServletException ...

What is the best way to use Date object with JDBC?

792 byte By yu_hung at 2007-9-26 3:46:04
Hi there,I need to store and retrieve Date from the Oracle database and I just want to know what is the best way to do that. I have tried to use the java.sql.Date object but its Date(int year, int month, int date) constructor, getYear(), getMonth and getDate() methods are deprecated. But I also ...

Uploading files

184 byte By arun_jassiar1 at 2007-9-26 3:47:04
i want to upload files using servelets and jdbc,please guide me , how could i approch the solution,if any of you done it earlier please help me also.

problrm in prepared statement

283 byte By fredyd at 2007-9-26 3:47:54
I am trying to updating a table using prepared statement using executeupdate(). I need to write to a reject file if my update fails , the rejected resultset. I have tried to use getresultset() on preparedstatement and it does not work. any sugessions please.fred