Top "Datetime" questions

A DateTime object in many programming languages describes a date and a time of day.

Converting between java.time.LocalDateTime and java.util.Date

Java 8 has a completely new API for date and time. One of the most useful classes in this API is …

java datetime java-8 java-time
how to extract only the year from the date in sql server 2008?

In sql server 2008, how to extract only the year from the date. In DB I have a column for date, …

sql sql-server-2008 datetime extract
Determine Whether Two Date Ranges Overlap

Given two date ranges, what is the simplest or most efficient way to determine whether the two date ranges overlap? …

datetime math language-agnostic
Convert datetime to Unix timestamp and convert it back in python

I have dt = datetime(2013,9,1,11), and I would like to get a Unix timestamp of this datetime object. When I do (…

python datetime timestamp
How do I calculate the date six months from the current date using the datetime Python module?

I am using the datetime Python module. I am looking to calculate the date 6 months from the current date. Could …

python datetime
How can I convert a datetime object to milliseconds since epoch (unix time) in Python?

I have a Python datetime object that I want to convert to unix time, or seconds/milliseconds since the 1970 epoch. …

python datetime epoch
How to change time in DateTime?

How can I change only the time in my DateTime variable "s"? DateTime s = some datetime;

c# datetime time
Daylight saving time and time zone best practices

I am hoping to make this question and the answers to it the definitive guide to dealing with daylight saving …

datetime timezone utc dst datetimeoffset
Datetime in where clause

How can I select 12/20/2008 in where clause of sql? The server is SQL server 2005. select * from tblErrorLog where errorDate = '12/20/2008…

sql sql-server datetime sql-server-2005 filter
Subtract one day from datetime

I have a query to fetch date diff between 2 datetime as : SELECT DATEDIFF(DAY, @CreatedDate , GETDATE()) Ex : SELECT DATEDIFF(DAY, …

sql sql-server datetime