Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

datalakeyu
Valued Contributor

Qlik Sense FileTime function does not work

I have a Qlik qvf file.

The file name is: 'FileTimetest.qvf'.

The file directory is: 'C:\Map_data_and_kml\FileTimetest.qvf'.

I would like to get the Qlik qvf file time of 'FileTimetest.qvf' and show it at Qlik sheet.

I use the following:

LOAD *, FileTime( 'C://Map_data_and_kml/FileTimetest.qvf') as filetimetest ;

LOAD *, FileTime( 'C:\Map_data_and_kml\FileTimetest.qvf') as filetimetest ;

Neither of the above works.

The used excel file is at the same directory with Qlik qvf file.

Could you please give any suggestion?

Thanks!

The script is as the following:

[ccomp$]:

LOAD *, FileTime( 'C://Map_data_and_kml/FileTimetest.qvf') as filetimetest ;

// LOAD *, FileTime( 'C:\Map_data_and_kml\FileTimetest.qvf') as filetimetest ;

// LOAD *, FileTime( ) as filetimetest ;

LOAD

[STORE_CODE],

  [STORENAME],

  [STATE],

  [REGION],

  [City],

  [Latitude],

  [Longitude]

FROM [lib://Map_data_and_kml/sample_data.xls]

(biff, embedded labels, table is ccomp$);

1 Solution

Accepted Solutions
Not applicable

Re: Qlik Sense FileTime function does not work

Hi,

You can try FileTime('lib://ha/test.qvf') but inside load script from another table. You can't just load it on its own.

For example, you can try add the file time to this table load

LOAD

[STORE_CODE],

  [STORENAME],

  [STATE],

  [REGION],

  [City],

  [Latitude],

  [Longitude],

  FileTime('lib://ha/test.qvf') as testtime

FROM [lib://Map_data_and_kml/sample_data.xls]

(biff, embedded labels, table is ccomp$);

2 Replies
Not applicable

Re: Qlik Sense FileTime function does not work

Hi,

You can try FileTime('lib://ha/test.qvf') but inside load script from another table. You can't just load it on its own.

For example, you can try add the file time to this table load

LOAD

[STORE_CODE],

  [STORENAME],

  [STATE],

  [REGION],

  [City],

  [Latitude],

  [Longitude],

  FileTime('lib://ha/test.qvf') as testtime

FROM [lib://Map_data_and_kml/sample_data.xls]

(biff, embedded labels, table is ccomp$);

datalakeyu
Valued Contributor

Re: Qlik Sense FileTime function does not work

Hi Nhu, thanks so much for your help!

Your suggestion works perfectly.

Firstly, we can not use another Load.

We have to use the file dictionary as  FileTime( 'lib://file name/'  )

The following example at Qlik sense help does not work:

In legacy scripting mode, the following path formats are also supported:

  • absolute Example: c:\data\

Community Browser