This week's book giveaway is in the OCPJP forum. We're giving away four copies of OCA/OCP Java SE 7 Programmer I & II Study Guide and have Kathy Sierra & Bert Bates on-line! See this thread for details.
I have the code below where I am querying my database based on some parameters and one of them is a date field where I am passing in a java util Date...
In the debug console I can see this come out as follows...
In the DB the value of the Settlement Date field is just "2013-01-27" but as you can see I am passing "Sun Jan 27 00:00:00 EST 2013". Could this be the reason why it is not finding the record? And if so how do I make it to pick it up? All the other fields of my query are present in the DB record.
Thanks in advance for any help.
Joined: Apr 30, 2002
I was able to resolve this by casting java util Date to java sql Date.
subject: Passing Date as parameter in SQL (Hibernate) where clause