Hello Javaranch,
. I'm writing back into this one because it's been over two weeks in the
IDE board, and I'm not convinced the problem is the environment.
. I've been editing a program in JBuilder Foundation 2005 that is written as if it should connect to SQL, but doesn't. I instead get:
SQLException: No suitable driver
SQLState: 08001
VendorError: 0 . I've also written a microprogram. All it does is connect to the database. And it doesn't throw the above error.
. I've also added to the above program to have it edit the database, and that also works.
. All the research I've seen on "No suitable driver" has said that either the Class.forName isn't working, or I'm naming the wrong driver. If either were the case, I don't think the microprogram would work, since it uses exactly the same terminology. Also, I have a separate check for the Class.forName, and that error isn't thrown.
. The unpleasant possibility is that this is one of those odd behaviours that changes when a comment line is added, rather than being based on the actual code. Or something that shifted in the versions, except then I'm not sure the microprogram should work. I know
Java's supposed to be portable and stable, but I can't find the needle in this haystack.
. Anyways, here's the offending code block, as best I can tell, in the macroprogram. Italics are comments I'm adding now rather than in the actual program.
So what's a good error-checking heuristic for this kind of problem? What do I look for: Java versions, newer drivers, nicer compilers, or should I just rewrite the macroprogram around the outside of the working microprogram?
Thanks for taking a look,