Date Output Format Differences - VisualCron - Forum

Community forum

Librus Prime
2019-12-06T17:35:50Z
I run a stored proc on 2 Hosts.
Host 1 is via sqlcmd
Host 2 is via VisualCron

I have output difference (below):
Host 1 Output = 2019-11-15
Host 2 Output = 2019-11-15 12:00:00 AM

Note:
1 - Region Settings are the same on Host 1 and Host 2
2 - The stored proc casts as "date" and not "date/time"
Example: cast(EndingDate as date )[ EndingDate],

Why are the outputs different?
How can I ensure that VisualCron outputs Date and not Date/Time ?

R
Librus Prime
2019-12-09T17:45:46Z
Is there a typical response time for "Rank: Paid Support" ?
Support
2019-12-09T19:13:29Z
Hi, this post was a duplicate to the email we answered. As mentioned first choice is to alter the query to the exact format you need. Please note that this is not a question directly related to VisualCron functionality but rather T-SQL question.


Here is some information for those that are interested in SQL date formatting:

SELECT convert(varchar, getdate(), 100) -- mon dd yyyy hh:mmAM

SELECT convert(varchar, getdate(), 101) -- mm/dd/yyyy – 10/02/2008                  

SELECT convert(varchar, getdate(), 102) -- yyyy.mm.dd – 2008.10.02           

SELECT convert(varchar, getdate(), 103) -- dd/mm/yyyy

SELECT convert(varchar, getdate(), 104) -- dd.mm.yyyy

SELECT convert(varchar, getdate(), 105) -- dd-mm-yyyy

SELECT convert(varchar, getdate(), 106) -- dd mon yyyy

SELECT convert(varchar, getdate(), 107) -- mon dd, yyyy

SELECT convert(varchar, getdate(), 108) -- hh:mm:ss

SELECT convert(varchar, getdate(), 109) -- mon dd yyyy hh:mm:ss:mmmAM (or PM)

SELECT convert(varchar, getdate(), 110) -- mm-dd-yyyy

SELECT convert(varchar, getdate(), 111) -- yyyy/mm/dd

SELECT convert(varchar, getdate(), 112) -- yyyymmdd

SELECT convert(varchar, getdate(), 113) -- dd mon yyyy hh:mm:ss:mmm

SELECT convert(varchar, getdate(), 114) -- hh:mm:ss:mmm(24h)

SELECT convert(varchar, getdate(), 120) -- yyyy-mm-dd hh:mm:ss(24h)

SELECT convert(varchar, getdate(), 121) -- yyyy-mm-dd hh:mm:ss.mmm

SELECT convert(varchar, getdate(), 126) -- yyyy-mm-ddThh:mm:ss.mmm



Henrik
Support
http://www.visualcron.com 
Please like  VisualCron on facebook!
Scroll to Top