Description
On mssql, the Test Evolution Gadget stops working if the dateformat it's not set to "mdy".
If in the database configuration the dateformat it's not set to "mdy", Xray will throw an Exception when using the Test Evolution Gadget.
/rest/raven/1.0/chart/test/evolution [c.x.r.dao.impl.TestsEvolutionDAOImpl] Error executing Test Evolution select statement com.microsoft.sqlserver.jdbc.SQLServerException: The conversion of a varchar data type to a datetime data type resulted in an out-of-range value. at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(SQLServerException.java:258) at com.microsoft.sqlserver.jdbc.SQLServerResultSet$FetchBuffer.nextRow(SQLServerResultSet.java:6309) at com.microsoft.sqlserver.jdbc.SQLServerResultSet.fetchBufferNext(SQLServerResultSet.java:1651) at com.microsoft.sqlserver.jdbc.SQLServerResultSet.next(SQLServerResultSet.java:987) at org.apache.commons.dbcp2.DelegatingResultSet.next(DelegatingResultSet.java:191) at org.apache.commons.dbcp2.DelegatingResultSet.next(DelegatingResultSet.java:191) at com.xpandit.raven.dao.impl.TestsEvolutionDAOImpl.a(Unknown Source) at com.xpandit.raven.dao.impl.TestsEvolutionDAOImpl.a(Unknown Source)
Â
Xray should be able to handle any dateformat configuration set by the customer.
Steps to reproduce:
- Check your mssql database configuration. Look for the dateformat entry.
DBCC USEROPTIONS;
- If the dateformat it's set to "mdy", change it to "dmy"
SET DATEFORMAT dmy;
- Make the Test Evolution Gadget Rest API call
<server>/rest/raven/1.0/chart/test/evolution?dateScope=timeFrame&timeFrame=currentWeek&testExecSavedFilter=10004&lastDays=6&_=1577455253142
- The call will return empty result, even when they exist. If you check the Jira's logs, you will see the mentioned error.
Attachments
Issue Links
- relates to
-
XRAY-3791 Test Runs Summary, unsupported date format in SQL Server
- Closed