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?
See below:
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 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])
)
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 ?
Correct. I am using a different table to be shown here (Show if).
Try this and update
ISNOTBLANK(
ANY(
FILTER(TimeCard,
AND(
MAXROW("TimeCard","_RowNumber"),
TODAY() = [Date],
USEREMAIL() = [Employee ID],
ISNOTBLANK([Time In]),
ISNOTBLANK([Time out])
))
)
)
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.
Same issue:
Then I should look into your app. For fixing this
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
...,
)
...
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])
)
)
)
Thanks I tried this but it did not work:
Wrap with isnotblank
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])
)
)
)
)
I couldn't understand it
In this table if there is NO row yet for today, then my view should show.
If there is already rows for today date, then the expression you wrote for me works. But if there are NO rows yet for today I need it to show.
Here is the view I am trying to show IF:
What you gave me worked fine. But I did not consider when the new day starts. ISNOTBLANK... will not work. I need to show this when there is a new day = meaning NO rows for the day have been logged yet.
Ok. What is the response from the expression assistant?
ISBLANK(any(FILTER(Timecard,
AND(
TODAY() = [Date],
USEREMAIL() = [Employee ID]
)))),
so when I add the ISBLANK... NO errors. However, the view shows ALL the time and NEVER goes away?
Wait. So now IT DID GO AWAY?
Hang on....
It's acting strange. sometimes it goes away (as it should) and sometimes it does not?
I added ANY to my expression like yours but the "Clock In" button still shows EVEN though it should not be:
Right now according to my table - the "Clock In" Button (above image) should NOT be showing as the employee is "Clocked in" already:
This is my updated expression (no errors):
OR(
ISBLANK(ANY(FILTER(Timecard,
AND(
TODAY() = [Date],
USEREMAIL() = [Employee ID]
)))),
ISNOTBLANK(
MAXROW("TimeCard","_RowNumber",
AND(
TODAY() = [Date],
USEREMAIL() = [Employee ID],
ISNOTBLANK([Time In]),
ISNOTBLANK([Time out])
)
)
)
)
I want to look under the hood bro.
How do I share the app with you?
My email id (PII Removed by Staff)
Give editor access of the app.
Sorry for the delay I had to ask my boss for the ok before sharing this. I will try and share it with you today.
What is your email? It is asking for that?
Sorry, what is your email please? I want to give you access.
Sent in pvt
I sent the app link email to you. I wasn't sure if you had a chance to look into my app yet.
APP name....?
TS - JOB BOARD
There are several tables, slices, actions. I could not find where it it.
Here is it:
Any luck finding that view in my app? I am sorry, my app definition may not be that organized.
<PII removed by staff>.
So I don't think you are able to show me your email here. This is what I keep seeing:
Even when I test the expression it CLEARLY states (NO) the view should NOT be shown and yet it still is?
User | Count |
---|---|
36 | |
31 | |
30 | |
20 | |
17 |