Hi,
Been working my way through OJB, and ran into this issue once and
though won't do it again probably, it would be good if there was a
better exception thrown for it. The issue is that I wrote my query
like this:
String sql = "select homes from " + HomeBO.class.getName();
sql += "where name = $1";
At first glance things look ok, but they're not, there is no space
before the where. Now we all write code fast and miss little things
like that. The issue I have is that the error thrown is a
NullPointerException. In my mind I was thinking maybe the value of $1
was null and that's why it was throwing that, thereby sending me into a
witch hunt, whereas in fact the issue is that HomeBO.class.getName() +
where does not translate into the proper class name.
Since the exception is thrown when I do query.create(sql) It would be
much better if the error thrown was a ClassNotFoundException, plus the
class name, instead of an NPE. Is that possible to get? This way if
the String of the class name printed to the error line returns as
com.codepuccino.data.ojb.HomeImplwhere we know immediately that we
missed a space somewhere.
Thanks
R
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
- Re: Enhancement request before 1.0 Robert S. Sfeir
- Re: Enhancement request before 1.0 Thomas Mahler
- Re: Enhancement request before 1.0 Robert S. Sfeir
- Re: Enhancement request before 1.0 Jakob Braeuchi
- Re: Enhancement request before 1.0 Robert S. Sfeir
- RE: Enhancement request before 1.0 Matthew Baird
- Re: Enhancement request before 1.0 Robert S. Sfeir
