Sep 01, 2020 11:15 AM
Hey guys im really dumb in Excel, I need some help.
First column is the item, then next one I have records for each, that is the stock. I’m struggling for an hour to find a formula which COUNTS how many rows are there, therefore I have the exact numbers of the rows, which is the stock for each item.
Thanks!
Solved! Go to Solution.
Sep 01, 2020 12:20 PM
Here’s a good guide on how to get started with making tables & linking records:
Sep 01, 2020 11:28 AM
Welcome to the community, @Tamas_Puskas!
Unlike Excel, Airtable doesn’t give us any formulas that can be used for counting/summarizing rows. The exception to this is the rollup field, but this only counts/summarizes rows of linked records from a linked table.
In your case, you will probably want to use the Summary Bar, which automatically gives you a variety of functions to use across rows. You can also group your records to get summaries of individual groups, as well.
Sep 01, 2020 11:36 AM
Thanks a lot for helping me!
Maybe I wasn’t clear enough: what I want to achieve is the following.
I have a column lets say
A
this has multiple records
x
y
z
I have another column
B
this has multiple records for each:
x :
a
b
c
y:
c
d
e
z:
f
g
I would like to get a 3rd column which is STOCK:
x: 3
y: 3
z : 2
which changes everytime if I delete a row
Sep 01, 2020 11:44 AM
I’m not sure I understand. Why don’t you post some screenshots or a video of your base?
Sep 01, 2020 11:56 AM
So item1 has 4 rows, and I need an automatic counter in “Exact number of stocks” column, which counts how many are there cause its hidden. Item2 has only one item, so stock is 1.
Sep 01, 2020 11:57 AM
Sep 01, 2020 12:14 PM
Those aren’t rows, those are line breaks within a rich text field.
That is not the ideal way to setup a database system. The ideal way is to ACTUALLY make each item its own row (i.e. record) in ANOTHER table that you link to via a linked record field. And then you can count the number of linked records by using the count field.
Off the top of my head, I’m not sure how to count number of line breaks in a rich text field. Airtable doesn’t give us any function to count the number of times a character appears within a string of text. I know that you can substitute the line break for commas by using the formula SUBSTITUTE({Field Name},"\n",",")
, but I’m not sure where to go from there.
Perhaps someone else can chime in on a good trick for counting commas or line breaks, but in the meantime, I would highly recommend setting up your database with proper table & record structure.
Sep 01, 2020 12:18 PM
Uhh okay, thank you very much!
Can you link me a guide to do that? Basically it’s just a simple thing, but I would really like if it looked something like this.
Sep 01, 2020 12:20 PM
Here’s a good guide on how to get started with making tables & linking records:
Sep 01, 2020 12:59 PM
I found a way to do this, thanks to @Justin_Barrett:
But — you should still go down the path of properly setting up your base! :slightly_smiling_face: