Win a copy of The Business Blockchain this week in the Cloud forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

I cannot control the record set Cursor - JDBC

 
jahanns
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Hi
Iam using the below mentioned things....
OS / webserver : Linux.
DatabaseServer: WinNT
Database :Oracle 8i
JDK : 1.2.2
JSDK 2.0
JDBC thin client driver.
Programming lang Servlets
my problem is that I cannot control the record set Cursor i.e moving the corsor to a fixed record in a table etc etc..
Is there a way though which i can do that ......do i need some additional drivers for that.....or i need to do some changes to the above mentioned configuration.
I would appreciate if you could send response at edwin@ctechindia.com
Regards
Edwin
Modified by John http://jahanns.virtualave.net/
 
Carl Trusiak
Sheriff
Posts: 3341
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by jahanns:

Hi
Iam using the below mentioned things....
OS / webserver : Linux.
DatabaseServer: WinNT
Database :Oracle 8i
JDK : 1.2.2
JSDK 2.0
JDBC thin client driver.
Programming lang Servlets
my problem is that I cannot control the record set Cursor i.e moving the corsor to a fixed record in a table etc etc..
Is there a way though which i can do that ......do i need some additional drivers for that.....or i need to do some changes to the above mentioned configuration.
I would appreciate if you could send response at edwin@ctechindia.com
Regards
Edwin
Modified by John http://jahanns.virtualave.net/

??? java.sql.ResultSet for jdk 1.2 has a rich set of methods for controlling cursor movements including next(), previous(), first(), last(), absolute(int row), relitive(int row) etc...
The system configuration you have listed above looks like it should support this. The only thing that I don't see is, what IDE are you using?

 
Edwin Abraham
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,
Thanx for your reply.
I dont use any IDE ........but i use TEXT Pad to write a servlet code.
I have tried using ResultSet.absolute() , ResultSet.Last() and stuff like that ...but it dosent work .
when i run the code with that ....it gives me
"501 Internal Server Error" in the browser. I think jdbc thin client does not support that kind of code or is it something else ........
any solution.?
Regards
Edwin
 
Carl Trusiak
Sheriff
Posts: 3341
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Edwin:
hi,
Thanx for your reply.
I dont use any IDE ........but i use TEXT Pad to write a servlet code.
I have tried using ResultSet.absolute() , ResultSet.Last() and stuff like that ...but it dosent work .
when i run the code with that ....it gives me
"501 Internal Server Error" in the browser. I think jdbc thin client does not support that kind of code or is it something else ........
any solution.?
Regards
Edwin

Your reply did bring bring back something. Oracle's jdbc drivers are written for and only support jdk 1.1! I don't know about the ODBC driver (or if they even have an install for it on linux), you could try it if you can find one and use the jdbc dbc driver. As a final you can implement the ResultSet in your own class and use collections to store the information on construction and navigate the collection objects.
 
Amit Zzz Kulkarni
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Check the Oracle technet site for driver details and post the Exception Stacktrace here.Mail me at my profile address if you do.
Amit
 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi all
if u want to move the cursor one by one don't make use of next(), last()..in the ResultSet interace...all these methods have to be supported by the drivers that u r going use...because some may support it while others may not..still it is diffucult and confusing to position the cursor...
the easiest way to do this is to put the entire resultset into an Hashtable. from the hashtable u can easiy read one by one or as a bunch as a whole using put and get methods
regards
mohan
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic