Tiger1
September 21, 2023, 5:25pm
1
I need the MAXROW evaluated. I also need a few other conditions checked as well. I cannot seem to get the MAXROW expression to work. All other conditions seem fine. I am using this as a “Show if” view.
Table = “Timecard”
Here is my expression:
ISNOTBLANK(FILTER(TimeCard,
AND(
MAXROW(“TimeCard”,“_RowNumber”),
TODAY() = [Date],
USEREMAIL() = [Employee ID],
ISNOTBLANK([Time In]),
ISNOTBLANK([Time out])
))
)
What error does it show ?
Could you please give me expression assistant screen shot ?
Why do you wrap the entire expression with isnotblank ?
What is your goal ?
Where are you applying this expression?
Try this alone. Update here about the status. Why did you use filter () in showif ?
AND(
MAXROW(“TimeCard”,“_RowNumber”),
TODAY() = [Date],
USEREMAIL() = [Employee ID],
ISNOTBLANK([Time In]),
ISNOTBLANK([Time out])
)
Tiger1
September 21, 2023, 5:41pm
5
This is a Show If, so when I take out ISNOTBLANK(FILTER… it cannot find anything…
Is this view doesn’t belong to same table ?
Tiger1
September 21, 2023, 5:54pm
7
Correct. I am using a different table to be shown here (Show if).
Error showing in the screen belongs to the expression which you have used there ? I am Asking this because it doesn’t look like it belongs to that and error has select function () which you have not used in expression.
Try this and update
ISNOTBLANK(
ANY(
FILTER(TimeCard,
AND(
MAXROW(“TimeCard”,“_RowNumber”),
TODAY() = [Date],
USEREMAIL() = [Employee ID],
ISNOTBLANK([Time In]),
ISNOTBLANK([Time out])
))
)
)
Tiger1
September 21, 2023, 6:01pm
10
Still getting the same error:
ISNOTBLANK(
ANY(
select(TimeCard[column name ],
AND(
MAXROW(“TimeCard”,“_RowNumber”),
TODAY() = [Date],
USEREMAIL() = [Employee ID],
ISNOTBLANK([Time In]),
ISNOTBLANK([Time out])
))
)
)
Please replace your column name with what you have.
Then I should look into your app. For fixing this
TeeSee1
September 22, 2023, 4:56am
14
I have taken only a cursory look but immediately I see one error as follows.
...
AND(
MAXROW(...), <- this is not a Yes/No expression. Every element in AND needs to be a yes/no
...,
)
...
3 Likes
Yes… I was thinking about it.
Maxrow could be wrapped before the before or after filter().
Expression needs some change.
Max(
select(tablename[column name],
AND(
TODAY() = [Date],
USEREMAIL() = [Employee ID],
ISNOTBLANK([Time In]),
ISNOTBLANK([Time out])
)
)
)
How about this:
ISNOTBLANK(
MAXROW(“TimeCard”,“_RowNumber”, AND(TODAY() = [Date],
USEREMAIL() = [Employee ID],
ISNOTBLANK([Time In]),
ISNOTBLANK([Time out])
)
)
)
2 Likes
Tiger1
September 22, 2023, 1:45pm
18
Thanks I tried this but it did not work:
Tiger1
September 22, 2023, 2:01pm
20
So I wrapped it in ISNOTBLANK and it worked! However I fogot about the scenario when it is a NEW day and no one has clocked in yet. In other words when [Date] <> TODAY(). I am trying to show this view when an employee clocks out ONLY. Then when they clock in - it goes away. However I need it to show if TODAY() and there are NO entries yet in my table, Does this make sense?
Table (TimeCard):
Keeping this in mind I added ISBLANK… But now that doesnt go away when it should.
OR(
ISBLANK(FILTER(Timecard,
AND(
TODAY() = [Date],
USEREMAIL() = [Employee ID]
))),
ISNOTBLANK(
MAXROW(“TimeCard”,“_RowNumber”,
AND(
TODAY() = [Date],
USEREMAIL() = [Employee ID],
ISNOTBLANK([Time In]),
ISNOTBLANK([Time out])
)
)
)
)