File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JDBC and Relational Databases and the fly likes i need help with this code? plz Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC and Relational Databases
Bookmark "i need help with this code? plz" Watch "i need help with this code? plz" New topic

i need help with this code? plz

Aa'ed Qarta

Joined: Jun 05, 2004
Posts: 1
hey there,
i'm new to JDBC stuff, so i did my best to make a simple SQL editor for my university project. i need to know how to return my connection object in this code..

// sorry the code is long...but i really need this! :>

knowledge iz power
Jeanne Boyarsky
author & internet detective

Joined: May 26, 2003
Posts: 33130

I would strongly favor passing the SQL and just executing the query in one place rather than trying to pass the connection around. You don't want the connection open for longer than neccessary as it wastes resources.

[OCA 8 book] [Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Other Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, TOGAF part 1 and part 2
I agree. Here's the link:
subject: i need help with this code? plz
It's not a secret anymore!