Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all there,
I'm a fairly new guy here in the QlikView community,
I'm having some difficulties putting a Transact SQL statement into QlikView.
Can someone give me an Idea in the right direction?
Statement:
CASE DUEBYTIME WHEN 0 THEN NULL
ELSE dateadd(s, datediff(s, GETUTCDATE(), getdate()) + (DUEBYTIME / 1000), '1970-01-01 00:00:00') END AS Verval_Datum
Thanks in advance.
Try with this:
(case when (DUEBYTIME=0) then Null() else dateadd(s, datediff(s, GETUTCDATE(), getdate()) + (DUEBYTIME / 1000), '1970-01-01 00:00:00') end) As Verval_Datum
Hi quique,
It seems Qlikview is troubled with te expressions:
dateadd(s, datediff(s, GETUTCDATE(), getdate())
ave you got there an QV alternative?
Thx in advance.
hi herman
try this
if(DUEBYTIME=0,Null(),Date(addmonths(datefield,'DD/MM/YYYY'),0)+(DUEBYTIME / 1000))As Verval_Datum
please specified that s,GETUTCDATE what are these fields or table name
thanks
rohit'
GETUTCDATE() is a transact SQL statement:
Microsoft writes:
Returns the current database system timestamp as a datetime value. The database time zone offset is not included. This value represents the current UTC time (Coordinated Universal Time). This value is derived from the operating system of the computer on which the instance of SQL Server is running.
Verval_Datum is a alias for a talbefield related to the field DUEBYTIME.
Greetz, Herman.