Help with maxrow() function

APP FUNCIONALITY
The main function of my app is to scann a certain employee with a scanner field and the app has to give me the ENTRANCE HOUR as well as the EXIT HOUR in order to calculate the hours worked.

The thing is that the user has to scan a card that will be assigned in a field called SCANNER_CARD, and the app automatically has to show me the hour depending of the entry type , (ENTRANCE HOUR or EXIT HOUR)
I know that I can do the time funcionality with timenow() and other funcionts
but I donโ€™t know how to automate this process.

What data do I have?

TABLES

Employees:

Table that has the following columns:
NUMBER (ID)
NAME (TEXT)

Timesheet :

Table that has the following columns
ID_TIMESHEET
SCANNER_CARD (References the NUMBER of the employee that is on employees
table)
DATE-DAY (DATETIME)
ENTRANCE HOUR (TIME)
OUTHOUR (TIME)

What have I tried?

I have tried to use the MAXROW() function to identify the last value of the DATE-DAY column so that I can compare it to the penultimate value of the column DATE-DAY as well

!!!ATTENTION!!!
I have tried to use the MAXROW() function to identify the last value of the DATE-DAY
but from the employee who was scanned not all data in general.

I donโ€™t know how to implement this pseudocode in appsheet expression Iโ€™ve been researching the documentation for over two weeks and I canโ€™t figure it out, please help me:

(assuming I already scanned the employee)

bring me the maxrow of the column DATE-DAY of the employee scanned
and

bring me the penultimate column of DATE-DAY of the same employee scanned

Please, I hope Iโ€™ve made myself clear. Thankyou

0 4 187
4 REPLIES 4
Top Labels in this Space