aspose file tools*
The moose likes JDBC and the fly likes database connection using ms access Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "database connection using ms access" Watch "database connection using ms access" New topic
Author

database connection using ms access

rafael pascual
Greenhorn

Joined: Jul 17, 2007
Posts: 2
i have a problem with my database connection...i am trying to get all the data in my database wherein my identifier is an integer...i chose autonumber in ms access...now what is wrong with my statement??
String sql = "SELECT * from tableName where studNum = '" + Integer.parseInt(txtNumber.getText()) + "'"

there is an exception and it says there that there is a type mismatch...

thanks!
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60053
    
  65

Originally posted by rafael pascual:
there is an exception and it says there that there is a type mismatch...

Showing us the actual details of the exception would be a good start to getting this solved.
[ October 16, 2007: Message edited by: Bear Bibeault ]

[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: database connection using ms access
 
Similar Threads
Performance Problems with DB Connection
applet with MS Access database
Connecting to MS Access 2000
JDBC - Access Connection
Can I use jdbc:odbc to access MS Access database remotely?