Hi,
Is there a network trip involved when I do a resultset.getInt() or resultset.getString() in the DAO layer ?
Is this different for different drivers ? If so, how does it work for DB2 ?
-
Does resultset.getInt result in a network trip (2 messages)
- Posted by: Jeetendra Dassani
- Posted on: December 14 2004 17:34 EST
Threaded Messages (2)
- Does resultset.getInt result in a network trip by Ruslan Zenin on December 15 2004 00:07 EST
- Does resultset.getInt result in a network trip by Pampa S B on December 29 2004 00:51 EST
-
Does resultset.getInt result in a network trip[ Go to top ]
- Posted by: Ruslan Zenin
- Posted on: December 15 2004 00:07 EST
- in response to Jeetendra Dassani
Hi,Is there a network trip involved when I do a resultset.getInt() or resultset.getString() in the DAO layer ?Is this different for different drivers ? If so, how does it work for DB2 ?
I would imagine that it is up to JDBC driver implementation. Some might have all the data fetched, some not.
Cannot say anything about DB2 - don't use it. -
Does resultset.getInt result in a network trip[ Go to top ]
- Posted by: Pampa S B
- Posted on: December 29 2004 00:51 EST
- in response to Jeetendra Dassani
It does not result in network trip again. Its stupidity on the part of the JDBC drivers to implement such kind of mechanism. As far I know, the object is at the client side which has the records from the database. You iterate through and get the data. So resultset.getInt will fetch you the data from the object rather than again making the round trip to the DB server.