Jump to content
We've recently updated our Privacy Statement, available here ×

set an instance of java.util.Calendar to midnight?


lpeel

Recommended Posts

Hi,

I'd like to set the time portion of a passed in parameter to midnight.   java equivalent is:
        cal.set(Calendar.HOUR_OF_DAY, 0);
        cal.set(Calendar.MINUTE, 0);
        cal.set(Calendar.SECOND, 0);

I've searched the web for several hours now and it looks like I have only 2 options:

1. Remove the time portion of the parameter in the SQL statement 

2. create a tiny jar file with just a few Java statements in it.

Does anyone have another way to set a default values for calendar object?

Thanks!

 

 

Link to comment
Share on other sites

  • Replies 0
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...