List of video embeds

Hi all. New to glide. Trying to make a mobile app with a data-driven list of videos, which can then be filtered.

I don’t want to have to make a new “video” component for every new video. I’d also rather not have to have a list of titles with images, which you then click through to view the video.

Is this possible? Or am I asking too much? :frowning:

Thanks for anyone’s help!

Hello, are you looking for something like this?

if so, just use a custom collection and include a video component. The video is not an image, if you click the play button it plays on the screen.

How is that data-driven though? I want to provide a list of videos to the app, and then have it list them out.

I’m a coder, I’ve built web apps for a living for a decade, and good lord I can’t seem to figure this UI out and make Glide work for me.

Sorry - should’ve said thank you for the reply. It’s appreciated.

How are your tables designed?
this is based on a video table. so each video is on a separate row.
If the video links are saved on the same row in different columns, then this way wont work

can you explain the exact use case?

Hi. No, they’re saved on different rows. I’m currently trying to figure out how to make a relational database!

I tried to use a table, then cards, but then I couldn’t seem to work out how to put a video component INSIDE the table cell.

It’s just a scrolling list of videos, which I’d like to be able to filter down. Thanks for your help on this

unless i am misunderstanding you, and if you are using glide apps (the new glide, not ‘classic’)

all you need is a custom collection. not sure if the below image helps

1 Like

As @abdo pointed out, a Custom Collection will give you a list based on rows, but inside each list item, you can add components, such as a Video component.

As for filtering the list/collection, you may need to explain your database some more. You mentioned a relational database, so I assume you have a table of categories. I also assume you have a Videos table that also lists the category for each video along with the video url. You need to create a relation column in your category table that links the category to the category in the Video table. The category table would be the source of your primary collection. When you click to view the detail screen of a category, then you can add a custom collection that is sourced from the relation. In that custom collection container, add the video component.

1 Like

Ok, so - thank you! I tried literally everything except that. A Custom Collection. Thank you.

@Jeff_Hager As for the relational side of things, everything is a little backward. I’m used to working with actual databases, so it’s taking me a little while to get used to spreadsheet world!

I have a videos table, with a name, desc, link, image etc. I also have a “filters” table, and then a “tags” table. The tags are essentially sub-filters, so they have the row ID from the filter in.

After that, I’m kinda … at a loss.

I only seem able to filter on the values of the table being used (ie. the videos table)

Can you share some screenshots of your data so we can better visualize it.

I hardly have any data, like literally 5 rows, I didn’t realise it would be this hard so I just typed the data in to a spreadsheet! I think it’s all backwards anyway, from what you’re saying - and from the fact I can’t figure it out at all.

Basically - I have videos. Those videos will be tagged, and I want to filter on the tag.

Imagine it with cars:

Load the app, all the cars display
Filter on size, and choose medium AND large (narrow selection down)
Filter on colour and choose red AND green (narrow selection down)

That’s it.

I’m guess I’m looking for something more specific to help guide you. Visualizing helps me see how your data is structured and then I can point out what you need to do using your current columns columns and tables.

But, I guess I have more questions. How do you want the filters to work? Are you using choice components (dropdown) or text entry? How are your tags structured? Are they comma delimited, or an array? What kind of values do your filters hold? How is the filter table structured? How is the tag table structured? Do you have tags in your video table, or are you using the tags table as an intermediary between filters and videos?

Sorry, trying to read between the lines to get a mental image. It’s hard to say at this point if you need to restructure your data or not. On the surface, I would say that you could get away with only the video table and use the built in glide filters, or if you need something more robust, then maybe you need a video table and a filter table. The filter table would be a single row table that temporarily holds filter values used to filter your videos, and you populate the filters with some choice components or text entry components.

I feel that glide as a database functions very similar to a traditional relational database, but with the added benefit of essentially being able to run code within the table.

I’ve structured it like a SQL database. A row for everything. Link tables. Foreign keys to link them all etc. That’s why I’m not screengrabbing it, because it feels like I’m doing it wrong! I guess it would be pretty hard to write a line for all these different tables on save/edit.

So my basic question would be this - how do I get the videos to have tags on it? I linked with with VideoTags, but the linked column wouldn’t show on the filters.

[edit - I deleted all the foreign keys because I was going round in circles]

I think link tables would be unnecessary. Each table should serve its purpose, and you use relation columns to create the links between tables. The way you are trying to do it will add a lot of unnecessary rows and possibly a lot of unnecessary edits to populate a bunch of extra tables with link data.

Create a new mobile glide project and study how that links categories and items together. That should help your understanding.

I would have a text column that gets populated with a comma delimited list of tags. Then use a Split Text column to convert it into an array. You can then use that array with relations. 1-N, N-1, or N-N

1 Like

Thank you for the help, and sorry for the delay. Sleep and work, in that order (UK).

I don’t think videos to tags directly can work, as a tag could have numerous videos, and a video could have numerous tags. But I notice that there is a row limit to the storage, so I can see why you are advising comma separating and array conversion etc.

I’ll give it a go. Thanks again.