Help

Counting records in a view that match a certain criteria

6626 11
cancel
Showing results for 
Search instead for 
Did you mean: 
Curation_Juniqe
5 - Automation Enthusiast
5 - Automation Enthusiast

I am using airtable for a somewhat unlikely use case, namely as a tool to visually merchandise catalog pages on a webshop.

Basically, I am using a table called SHOP in the catalog view to drag-and-drop images directly from our webshop onto a record / attachment field and am using a formula to extract our product code from the attachment field, as the attachment name literally holds the unique product identifier.
Each product code is consisting of a prefix and a code, indicating supplier and product and I have both split as two separate fields by formula.

First, I would need to establish how many times the code prefix field and the code field are listed in a view, in google sheets a basic COUNTIF Formula, which I understand is not as basic in AirTable. The product code field is actually linked, but the prefix field at the moment, is not.

Additionally, I am pulling data from another table based calles SALES on the code, such as sales figures, engagement data, etc, which is being pulled via a lookup field onto the main table.
Currently, this requires me to manually duplicate the entire column that holds the product code and paste it into the linked field column to establish the relation to the sales data records in the SALES table. This does work but is a bit cumbersome, is there any way to dynamically link a formula-calculated field to a related record in another table?

Any help would be greatly appreciated!

11 Replies 11

Hi Elias,
I’ve just been exploring this option a little and while it does have it’s advantages, I am also seeing some issues with that operationally. Hear me out, and please change my mind if you can :slightly_smiling_face:

I am now using a rollup field with arrayjoin on the curation table to pull the linked records.
Since they’re the same value, it doesn’t let me count them directly but I have created a separate field counting the commas in the rollup, which gives me the amount of (identical) values in there.

  1. So for one, the manual steps would still be there when setting up a new curation via a view/single-select field - i’d need to duplicate the view instead of the table but also configure the counter to listen to a new condition (the single select field, like Female Icons, Boho - btw kudos on your understanding of our customers) and have users create a new value for the single select field
    This seems a little more error-prone than just letting user pick another linked field when duplicating their table

  2. We will inevitably end up creating multiple instances of the same record in the main table - certain bestsellers will be featured in numerous collections and curations, because the process of picking them is quite intuitive and spontaneous and involves a lot of different options being tried out, I would oftentimes see a scenario where people enter a new record that’s already in that table but hidden in this new view, and will need to be featured in different positions in different views.
    This could mean that we could either use multiple select fields, which would still mean running risks described in point 1) but also, in the way we curate these shops, it would be a lot easier just dragging another shop image onto a fresh record, hence creating a dupe - which would be easy when working with multiple tables but is a bit harder when talking about views.

I have an idea as how to handle curation tables — but it’s pretty much orthogonal to traditional Airtable development, and whether it is suitable depends heavily upon your work flow. (It’s a byproduct of some work I did for a client about six months ago. It wasn’t quite right for him — his use of Airtable had been dictated to him by a client, so they could commingle bases, and any gains in efficiency on his end would have been lost in the additional work needed to pound the data back into a shape his client expected — and ever since I’ve been stubbornly looking for a problem for this solution.)

Unfortunately, I’m currently even harder to get hold of than usual, as at some point over the next few days I’ll be relocating from the West Coast to the East, for a period of somewhere between one month and the rest of my life. (Presumably those aren’t synonymous.) Before I fly off, I’ll try to send you a PM here describing the approach; if it sounds feasible, we can discuss it in more detail when I resurface, which I hope will be later next week…