Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

jdbc resousces?

Options
  • 17-10-2001 1:18am
    #1
    Registered Users Posts: 6,661 ✭✭✭


    Does anyone know of a good book/website for JDBC? The book I'm using is ****e for it. It basically uses a class method to do all the work without teaching you anything :(

    Also - does anyone know of a Java compiler? I've heard about ones that can compile to executable code instead of jbc but don't know which ones can.


Comments

  • Closed Accounts Posts: 37 nucular


    I have never heard of a java compiler as such.
    Usually the closest thing you will get to this is a JIT (just in time) compiler. This takes the java bytecode at runtime and compiles this into a machine readable format(rather than translating as it goes). These give a significant boost in performance.

    If the reason you want this is to have an executable instead of typing a command line or using a batch then there are some java launchers available but I don't know much about them.

    As far as JDBC goes it is not very difficult and there are some reasonable tutorials around. Other than that I don't really know.


  • Closed Accounts Posts: 1,322 ✭✭✭phobos


    First things first....

    Don't tell me that you want to code in Java, and that you want to create an executable. Executables are platform specific programs. JIT is something completely different, but will improve performance. I guess that you want executables so you will make it easier for end users to lauch your javaware. Your best bet is to learn how to create executable JARs.

    WRT JDBC
    http://java.sun.com/docs/books/tutorial/jdbc/basics/

    There are good tutorials on every aspect of Java online. But you are always better off going to the source java.sun.com (where the above tutorial came from). There are several others, but I still think the original is still the best.

    HTH,
    ;-phobos-)


  • Registered Users Posts: 15,443 ✭✭✭✭bonkey


    re: executable compilation....

    If you are going platform-specific, then there is nothing wrong with .exe's, but to be honest, a .jar with a .bat file to launch it is probably just as easy. Alternately have a look at something like webstart as a deployment

    re: JDBC

    Phobos' link is pretty good. I think the same info is in the JDK documentation which you can download. If you *really* want a book, they're all pretty much the same. I used ORA's Java Enterprise in a nutshell for starting off with JDBC and other Enterprise APIs. ORA also do a full "Database programming with JDBC" book.

    To be honest, if you have worked with ODBC at all in MS languages (or DAO, RDO, ADO, etc.) then JDBC is gonna be a walk in the park, cause its mostly the same. Coming from a VB background, I found JDBC trivial to get to grips with - there's almost nothing new in it.

    One warning....again to do with ODBC...the JDBC/ODBC bridge, from my experience, is a horrid driver, and doesnt support all of the JDBC functionality. I had massive problems with it, for example, calling a stored procedure on MS SQL Servre 7 which had either output or return parameters.

    As a last option...go read the link Phobos posted, try out the code, and then post up here with your problems :) I'm sure there are plenty of Java-heads (including myself) who will help debug your code or answer specific questions on it.

    jc


  • Closed Accounts Posts: 1,651 ✭✭✭Enygma


    Kind of off-topic, here's an article about the JDBC3.0 spec
    http://www.onjava.com/pub/a/onjava/synd/2001/08/21/jdbc.html

    Most important thing in JDBC programming, close your connection in a finally clause, used always miss that one for some reason :)


  • Registered Users Posts: 6,661 ✭✭✭Blitzkrieger


    Thanks guys.
    Originally posted by bonkey
    ORA also do a full "Database programming with JDBC" book.

    Probably have a look for that. I always like to have lots of information I never use :)


    I don't think I meant JIT compilers. I heard that you could get compilers that compile directly to .exe. You'd still get the JBC of course and it'd still be cross platform - you just wouldn't get smug C++ gits going on about how it's 100 times faster.


  • Advertisement
Advertisement