Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
tomcatxx
Creator
Creator

Master calendar

Hi there, I have a Problem about calendar. That calender contains 14 days. Code is here.

//////////////////////////////////////////////////////////////

LET varMinDatum = Today()-14;
LET varMaxDatum = Today()+1;

Kalender:
LOAD *,
AutoNumber(%Datum, 'Schichttag') AS _D,
AutoNumber(Woche, 'Woche') AS _W,
AutoNumber(Jahr, 'Jahr') AS _J,
AutoNumber(Monat, 'Monat') AS _M,
AutoNumber(Quartal, 'Quartal') AS _Q;

LOAD Datumsfeld as %Datum,
week(Datumsfeld) as Woche,
year(Datumsfeld) as Jahr,
month(Datumsfeld) as Monat,
day(Datumsfeld) as Tag,

LOAD date($(varMinDatum)+IterNo()-1) as Datumsfeld
AUTOGENERATE 1 WHILE $(varMinDatum)+IterNo()-1<= $(varMaxDatum)
;

//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

Now I have data only on 03.05 , 04. 05, 11,05. For other days I have no data. But that shows only values of date for these 3 days.

%Datum
27.04.2018
28.04.2018
29.04.2018
30.04.2018
01.05.2018
02.05.2018
43223
43224
05.05.2018
06.05.2018
07.05.2018
08.05.2018
09.05.2018
10.05.2018
43237
12.05.2018

  

The data must be updated everyday with Join, when there are new data.

Load * From xxx;

Join

Load  xx,

          xx,

          Today() as %Datum;

1 Solution

Accepted Solutions
YoussefBelloum
Champion
Champion

Hi,

try this:

.

.

.

Load * From xxx;

Join

Load  xx,

          xx,

          Date(Today()) as %Datum;

View solution in original post

5 Replies
YoussefBelloum
Champion
Champion

Hi,

try this:

.

.

.

Load * From xxx;

Join

Load  xx,

          xx,

          Date(Today()) as %Datum;

tomcatxx
Creator
Creator
Author

Thank you. I thought it must work.

I tried it and Date(Today(), 'DD.MM.YYYY') as %Datum and  FileTime() as %Datum.

But they don't work.

YoussefBelloum
Champion
Champion

Would you be able to attach sample data or app ?

tomcatxx
Creator
Creator
Author

I tried it again. It works now. I think u are right. I missed something.

I have app like this.

Datasource.txt------>Generator.qvw------->Data_model.qvw-------> Dashborad.qvw------->Nprinting------>Excel

I just corrected  Date(Today()) as Datum in Generator.qvw. But the data will be loaded one more time in Data_model.qvw.  I didn't change Datum as %Datum in Data_model.qvw. So it didn't work.

Now I have also Date(Datum) as %Datum in Data_model.qvw. So it's perfect now.

Thank you.

YoussefBelloum
Champion
Champion

you're welcome.

.

Good luck