Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

Not applicable

timedate stamp convert to only mm/dd/yyyy

I am using the direct connect and need to convert a timedate stamp to be only date below is a copy of what I have

HRxs.InitReview as 'DateRange',

Tags (1)
1 Solution

Accepted Solutions

Re: timedate stamp convert to only mm/dd/yyyy

hrxs:

LOAD *,
          DayName(HRxs.InitReview) as DateRange;

SQL

Select HRxs.eRxMsgID,
          HRxs.FacID,
          HRxs.InitReview,

          HRxs.NewRx,
          HRxs.PackBy,
          HRxs.Packed
FROM Rx.dbo.HRxs

regards

Marco

6 Replies
Employee
Employee

Re: timedate stamp convert to only mm/dd/yyyy

Try

Date(Floor(HRxs.InitReview,'MM/DD/YYYY')) as 'DateRange',

Not applicable

Re: timedate stamp convert to only mm/dd/yyyy

The following error occurred:

ErrorSource: Microsoft OLE DB Provider for SQL Server, ErrorMsg: The floor function requires 1 argument(s).

Date(Floor(HRxs.InitReview,'MM/DD/YYYY')) as 'DateRange'

after removing the floor

Connected

The following error occurred:

ErrorSource: Microsoft OLE DB Provider for SQL Server, ErrorMsg: 'Date' is not a recognized built-in function name.

Re: timedate stamp convert to only mm/dd/yyyy

Use preceding load:

LOAD DayName(HRxs.InitReview) as DateRange;

SQL Select HRxs.InitReview

FROM YourDB;

hope this helps

regards

Marco

Not applicable

Re: timedate stamp convert to only mm/dd/yyyy

hrxs:

LOAD *;
SQL SELECT
,
HRxs.eRxMsgID,
HRxs.FacID,
HRxs.InitReview as DateRange,

HRxs.NewRx,
HRxs.PackBy,
HRxs.Packed,

LOAD
DayName(HRxs.InitReview) as DateRange;
SQL Select HRxs.InitReview 
FROM Rx.dbo.HRxs

Re: timedate stamp convert to only mm/dd/yyyy

hrxs:

LOAD *,
          DayName(HRxs.InitReview) as DateRange;

SQL

Select HRxs.eRxMsgID,
          HRxs.FacID,
          HRxs.InitReview,

          HRxs.NewRx,
          HRxs.PackBy,
          HRxs.Packed
FROM Rx.dbo.HRxs

regards

Marco

Employee
Employee

Re: timedate stamp convert to only mm/dd/yyyy

It´s supposed to be at Qlik scope

LOAD *,

Date(Floor(HRxs.InitReview,'MM/DD/YYYY')) as 'DateRange';

SQL

yourquery goes here

Community Browser