Row Owners via Dynamic Array

I have a scenario where an “admin” within the app would like to assign multiple users as row owners in a specific sheet. The number will vary so I cannot use the Email 1, EMail 2, Email 3 approach as suggested in the past by the likes of @ThinhDinh, @Jeff_Hager and @Robert_Petitto. Has anybody come up with an approach that solves this one yet? Thanks all.

I think you have 2 ways to deal with this:

  • Have a very crazy amount of columns in the array (like 10 or something), use the old method of setting row owners.

  • Let people input emails in a text component but you must make sure you either let them separate two emails by (", " or “,”), then use a split text and set that split as row owner. I haven’t actually tried this, just a wild idea.

I don’t think your 2nd point will work:

1 Like

Can’t you use Google sheets to do the split?

I suppose you could, but you’d still need to give your columns a header value (I’m not sure if that can be done dynamically in sheets with some sort of horizontal Arrayformula — never tried!).

Actually I guess pre-naming a bunch of columns is easier than creating all the separate fields in Glide, so this might end up quicker/easier as long as all the emails are separated properly in the first column using a common separator.

1 Like

I’ve tried it for some other purpose not emails. It’s making an array + split function. Only caveat is the number of emails can’t exceed the planned array columns.

1 Like

I’d be interested to see it in action if you get it working. Post some screenshots afterwards. Could be helpful for others too.

1 Like

We can do it, I have done this before.

1 Like

Guys. Thanks so much for the rapid input. This was of interest in particular:

So I guess I need to somehow create a mechanism that will dynamically populate an array column of emails. As I understand it, you can’t do this in the data editor (a relation is computed). You also can’t do it in a Google Sheet because you’d need to specify the column name “in advance” i.e. Email 1, Email 2 etc.

So … it can’t be done?

It can be done. I have done the “column name in advance” part before. Let me find it and send back to you.

2 Likes

Here you are. The formula inputs new column names in an array style when new values are added that increases the max number of columns required.

6 Likes

Thanks @ThinhDinh - will take a look shortly :crazy_face:

2 Likes

Nice! Thanks for sharing. That’s a wicked idea.

1 Like

To back up @ThinhDinh’s idea, I believe it’s true that you can add additional columns to an array without having to touch the app builder, and glide will recognize it automatically. They just need to be consecutive and next to each other. In situations like this, it’s best to put the arrays as the last columns to allow for growth. Don’t hold me to it though. I kind of remember trying it a year or so ago.

3 Likes

hey @ThinhDinh - I’m checking out your sheet. Any specific reason a new name doesn’t populate unless a new value is added to row 4, not 2 or 3? Does this formula have a max? I can see that w/o column A it stops at 11 items.

I’m thinking through this in the context of set column actions for Row Owner management.

Hi Rasha, I just checked and it still works as I expected. Can you specify what part doesn’t work?

Currently I limit it to column AA, you can increase that by specifying a larger column.

2 Likes

@ThinhDinh how strange - a copy of this sheet was behaving differently (PM’d you a link). This one works. Thanks for concocting this!

@V88 have you put this to test? How’s your admin assigning? It a nice solution when you’re working with a manageable number of row owners, switching on/off row ownership manually, and duplication is not a concern. Something to build on for sure.

Hi. I found a solution via roles so didn’t progress further. Sorry I can’t be of more help.

1 Like

Is there any way to now do this via native Glide features?

I have items that I would like to assign to groups of users using row owners (for security purposes), but the groups will change dynamically. Ie. Users can add remove viewers of the item.

For now I have just removed row owners in my sheet and am filtering the item view based on whether the logged in viewer has permission. But I understand this isn’t secure nor speedy if the item list gets long?

Any suggestions?

Do you have an upper limit for number of users you want to assign?