Enum column type - Required is not working properly

bugs-issues-errors
(John Henry Joseph) #1

I have an Enum column type in a table which is mandatory (required).
However, the system allows users to save a record without Enum column information.
How to prevent it?
FYI : The Enum column information is coming from other table.

(Levent Kulacoglu) #2

@John_Henry_Joseph
Do you have an expression in Required_if property or is it just set to ON? Can you also try setting below expression to Valid_if:

ISNOTBLANK([_THIS])

(John Henry Joseph) #3

I have below expression in Valid_if.
“SELECT(INSPECTION TEMPLATE[Checkpoint], ([Fleet Type] = [_THISROW].[Fleet Type])) - SELECT(INSPECTION CHECKLIST[Checkpoint], AND(([Fleet Type] = [_THISROW].[Fleet Type]), [Inspection Code] = [_THISROW].[Inspection Code]), ([_RowNumber] <> [_THISROW].[_RowNumber]))”

Require is ON.

Please advise.

(Levent Kulacoglu) #4

Your expression have redundant paranthesises, so you better remove them as it might confuse you. I have removed them away below.

SELECT(INSPECTION TEMPLATE[Checkpoint], [Fleet Type] = [_THISROW].[Fleet Type]) - SELECT(INSPECTION CHECKLIST[Checkpoint], AND([Fleet Type] = [_THISROW].[Fleet Type], [Inspection Code] = [_THISROW].[Inspection Code], [_RowNumber] <> [_THISROW].[_RowNumber]))

Try using above expression in Suggested values property and use below expression in Valid_if
ISNOTBLANK([_THIS])

2 Likes
(John Henry Joseph) #5

Thanks lot Mr. @LeventK… It works perfectly…

(Levent Kulacoglu) #6

You’re welcome @John_Henry_Joseph, truly my pleasure to be helped of.

(John Henry Joseph) #7

@LeventK
If you don’t mistake me… can i request one more clarification on below?

Consider the below Tables.
KPI - each row will hold a description of Key Performance Indicator.
KPI Members - Child table for KPI, where you can add “Team member” (key is KPI ID+Team Member.
User Updates - where the assigned users can provide their updates for KPI (reference from “KPI” table.
Now My problem is If anyone select a KPI, the system should identify the user should add a new updates or just only read.
So, I create a virtual column “Members List” in KPI Members table and applied the above suggested expression in “Are updates allowed” of “User Updates” table.
But, it doesn’t seem work. Can you please help me out.

Thanks in advance.

(Levent Kulacoglu) #8

@John_Henry_Joseph
It’s hard to say anything without knowing your sheet structure and your app structure as well. I have no idea how you had set the dependencies between tables. However, to allow user intervention with a table, you shall be reading some value from somewhere so that you can compare the values. For example:

Provided you are populating Team Member’s ID in that virtual column, and provided you can match that Member ID with an useremail in User Updates table, than you may evaluate the active user’s status like this:

IN(LOOKUP(USEREMAIL(),"User Updates","Email","Member ID"), KPI Members[Member List])