Solution: Entity SQL Date Functions
When writing the custom query, for example, you can display a list of incidents and their creation date/times as follows:
select R.INCIDENT_ID, R.CREATION_DATE from SpiraTestEntities.R_Incidents as R where R.PROJECT_ID = ${ProjectId}
This displays the following:
INCIDENT_ID | CREATION_DATE |
---|
1 | 2003-11-01T00:00:00 |
2 | 2003-11-01T00:00:00 |
3 | 2003-11-01T00:00:00 |
4 | 2003-11-02T00:00:00 |
5 | 2003-11-02T00:00:00 |
6 | 2003-11-02T00:00:00 |
7 | 2003-11-04T00:00:00 |
8 | 2003-11-04T00:00:00 |
9 | 2003-11-04T00:00:00 |
10 | 2003-11-04T00:00:00 |
To get just the date-values, you need to use the TruncateTime() function:
select R.INCIDENT_ID, TruncateTime(R.CREATION_DATE) as CREATION_DATE from SpiraTestEntities.R_Incidents as R where R.PROJECT_ID = ${ProjectId}
For a full list of date-related functions you can use in EntitySQL, please refer to:
https://msdn.microsoft.com/en-us/library/bb738563(v=vs.110).aspx