Qlik Community

Ask a Question

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

Announcements
Do More with Qlik - for Beginners and Beyond, Topic: Qlik Replicate on January 21, 2PM EST. REGISTER NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Partner
Partner

Next StartDate

Hi all,

My trip data contains the following:

Trips:

Load TripId

Customer

Vehicle

TripDuration

TripStartTimeDate
TripEndTimeDate

and loads of other fields, the table also links to various other tables, but:

I need to calculate the Total Time Stopped.  I was thinking of using the Next TripStartTimeDate - Current TripEndTimeDate to get the answer. 

I just cannot get the correct function to use, both Peek() and Previous() looks backwards and there is no Next() function to look forward into the data.

This data needs to be presented by Date, Customer and Vehicle

Hope you can help

2 Replies
Not applicable

But:

Current TripStartTimeDate - Previous TripEndTimeDate

should give you exactly the same result ....


you may for example:

a) add rowno() as id innto first table

b) join with  load Current TripStartTimeDate - Previous TripEndTimeDate, row() -1 as id from your table


regards

D

Partner
Partner

You are in the right path

If you need to calculate the time stopped by vehicle Order your table by date and vehicle then use peek and previous

To evaluate next record to identify the last record of each vehicle by date there is a sample in the community

Search it

When I arrive to my office I can find it for you

Hector garcia

Good look

Sent from my iPhone