Ref column doesn't work with SELECT FORMULA

a_can
New Member

So, I have an inspection app with three table INSPECTIONS, STAFF, AND LOCATION.
I assigned the user of the app as a default value to INSPECTOR column, column type is text and app formula is:

SELECT(STAFF[INSPECTOR], [EMAIL] = USEREMAIL(), TRUE)

By nature of the formula, it is working and the user of the app donโ€™t need write his name to the INSPECTOR column.

The problem is ref column donโ€™t accept app formula to evaluate the action above.

So I can not use reverse reference. Any idea is appreciatedโ€ฆ

Solved Solved
0 5 998
1 ACCEPTED SOLUTION

In order to dereference a value, the value must be of the Ref type. Based on what youโ€™ve shared, I would suggest you replace your SELECT() expression with the following:

ANY(
  FILTER(
    "STAFF",
    (USEREMAIL() = [EMAIL])
  )
)

This will produce a Ref to the row in the STAFF table that corresponds to the current app user. Also change the column type for the INSPECTOR column to Ref (if the app editor doesnโ€™t automatically change it) and set the columnโ€™s Source table to STAFF. Once the column type is properly set, youโ€™ll be able to dereference the column value in expressions.

See also:



View solution in original post

5 REPLIES 5
Top Labels in this Space