*
The moose likes Swing / AWT / SWT and the fly likes JTable and Resultset Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "JTable and Resultset" Watch "JTable and Resultset" New topic
Author

JTable and Resultset

manisha ankolekar
Greenhorn

Joined: Nov 26, 2006
Posts: 10
How to populate Jtable with resultset.Is DefaultTableModel fine???

In my appln user on the form selects dateand based on that record displayed on the table on button event.But on button event I'm getting JVM error as:

An unexpected error has been detected by Java Runtime Environment:
#
# EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x7c901010, pid=4080, tid=2660
#
# Java VM: Java HotSpot(TM) Client VM (1.6.0_03-b05 mixed mode, sharing)
# Problematic frame:
# C [ntdll.dll+0x1010]
#
# If you would like to submit a bug report, please visit:
# http://java.sun.com/webapps/bugreport/crash.jsp
#

Any Help appreciated.......
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19649
    
  18

Are you calling a third party application? Because this error is not caused by Java code but by native code. So unless you're using a third party application with a bug, or you've found a bug in the JVM.

Can you try to find out what the last line of Java code is that executes successfully before this error?


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
How To Ask Questions How To Answer Questions
manisha ankolekar
Greenhorn

Joined: Nov 26, 2006
Posts: 10
No,I am not using any third party application.Actually its gui applicationn wherein user selects date and retrieves data from db.Here I have used a button which calls method below:



Cant get what is the problem???
Please tell me any alternate method to fill the table on button event.
thank you
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19649
    
  18

What happens if you close() your pstmt and rs? Which is a good thing to do anyway - always close() (Prepared)Statements, ResultSets, Connections and even Readers and InputStreams when you're done with them.

You could also try using a different ODBC connector. I've read the default Sun implementation can be buggy at times. If you check the JDBC forum in the Saloon you're sure to find a good replacement.
Abdul Jabbar WebBestow
Greenhorn

Joined: Nov 23, 2012
Posts: 1
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: JTable and Resultset
 
Similar Threads
eclipse can not connect to mysql!!!
Weird error...
Java VM: Java HotSpot(TM) Client VM (1.5.0_01-b08 mixed mode, sharing)
Error executing servlet
unexpected Error