Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

Highlighted
wdchristensen
Valued Contributor

SET DateFormat='YYYY-MM-DD'; doesn’t recognize SQL Server dates

When I run the script below, Qlik Sense is treating the incoming dates as though they were text. I even attempted to use “CONVERT(varchar, getdate(), 23)” to ensure the data was coming in as a VARCHAR(10) in the 'YYYY-MM-DD' format and the values are still showing up at strings. I am using SQL Server 2016 and my connection is using the SQLOLEDB driver. 

The odd thing is that I have no issues with the TimeStampFormat. 

DateFormatIssue.png

Labels (1)
1 Solution

Accepted Solutions
wdchristensen
Valued Contributor

Re: SET DateFormat='YYYY-MM-DD'; doesn’t recognize SQL Server dates

Hey Buddy, 

I had the same issue and the root cause was the OLE DB driver. Try changing your connection to the "Microsoft SQL Server" driver. 

DriverTypeSQL_Server.png

1 Reply
wdchristensen
Valued Contributor

Re: SET DateFormat='YYYY-MM-DD'; doesn’t recognize SQL Server dates

Hey Buddy, 

I had the same issue and the root cause was the OLE DB driver. Try changing your connection to the "Microsoft SQL Server" driver. 

DriverTypeSQL_Server.png