Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

help in expression

Table 1:

timind_ID    Timing

1                 9 - 9:30

2                 9:30 - 10

3                10 - 10:30

Table2:

tiiming_ID  BookingDate

2               21/5/2012

3               22/5/2012

1               23/5/2012

1               22/5/2012

3               21/5/2012

Result:

Timing          21/5/2012       22/5/2012     23/5/2012

9-930            Booked                              Booked

9-30 - 10        Booked    

10- 10:30        Booked        Booked

4 Replies
swuehl
MVP
MVP

You could try it like this:

Just load your tables as is (I think in above post, there are some typos which probably are not part of your script?).

Then create a pivot table with dimensions BookingDate and Timing and as expression

=if(timing_ID, 'Booked')

Then drag BookingDate dimension to the top of the pivot.

Hope this helps,

Stefan

Anonymous
Not applicable
Author

i need to show today ,tomorrow,dayaftertomorrow booked date only...

Anonymous
Not applicable
Author

I tried like this but its not working

timing as dimension

expression like =if(Booking_Date = Today(), 'Booked','  ')

but its not working

swuehl
MVP
MVP

With my suggested chart, either try a calculated dimension instead of dimension BookingDate (still first dimension Timing):

=if(BookingDate>=today() and BookingDate<=today()+2,BookingDate)

(and check Suppress when Value is Null in dimension tab)

or a set expression as expression

=only({<BookingDate={">=$(=today())<=$(=today()+2)"}>} if(timing_ID,'Booked'))