• Post Reply Bookmark Topic Watch Topic
  • New Topic

week of the year

 
Alessandro Ilardo
Ranch Hand
Posts: 218
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have some problems with this named query (I'm using JBoss 4.2.2 with Hibernate embedded).


I want to retrieve just the entities, where the week of the year for the Calendar match the Integer passed as parameter :weekInput.
Apparently the sintax is fine, the jar runs correctly. But during the test I found out an incorrect behavior, I have a record which as the week property equals to the 16 of June, that corresponds to the week of the year 25. This query returns that resulset even if the week of the year passed is 24.
Have you got any suggestions?
 
Gravity is a harsh mistress. But this tiny ad is pretty easy to deal with:
the new thread boost feature: great for the advertiser and smooth for the coderanch user
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!