Help

A table expander script

3926 7
cancel
Showing results for 
Search instead for 
Did you mean: 
Suhas_Kulhalli
5 - Automation Enthusiast
5 - Automation Enthusiast

There is a table optimiser script. I want a script which does exactly the opposite. I have created the records using junction script. It is convenient to create and update. Can I not do the opposite.

This is the help for Table optimiser below - I want to do the exact opposite

Use this script to turn a “wide” table - one with individual records each with multiple different associated fields - into a “narrow” one - with a record for each associated field and field value.

For example, if your original table looked like:

|  Product  |  Jan Sales    |  Feb Sales    |  Mar Sales    |
-------------------------------------------------------------
|  A        |  32           |  168          |  180          |
|  B        |  24           |  150          |  175          |
|  C        |  64           |  144          |  165          |

You could use this script to automatically create a new “narrow” table, that would look like the following:

|    Product     |   Month Sales |   Sales       |
-------------------------------------------------
|    A           |   Jan Sales   |   32          |
|    A           |   Feb Sales   |   168         |
|    A           |   Mar Sales   |   180         |
|    B           |   Jan Sales   |   24          |
|    B           |   Feb Sales   |   150         |
|    B           |   Mar Sales   |   175         |
|    C           |   Jan Sales   |   64          |
|    C           |   Feb Sales   |   144         |
|    C           |   Mar Sales   |   165         |

This can then help make certain calculations and rollups more efficient.

7 Replies 7

I have to ask: if the existing script is designed to create a more efficient configuration, why would you want to do the opposite, essentially making the design less efficient? Could you please describe your use case in greater detail?

Justin, the viewing of the data is easier in the former case. I can quickly compare visually the sales figures between Jan and March for eg:, but in the other case it does not stand out.

Both have their advantages so ideally I would like to have both views possible

I can appreciate that to some extent, but this means that you will be frequently running this script that you’re asking for to create this alternate view of your data, which still sounds very inefficient in the long run.

Have you tried building a custom interface using Interface Designer? Interfaces are far better at acting as reporting/reviewing mechanisms than the raw table data itself, and Airtable is frequently updating the interface features to make more robust reporting possible. I recommend investigating what’s possible via a custom interface before leaning too heavily toward this alternate script that you’ve described.

Will the Pivot Table extension provide what you want?

Thanks Justin

In the recent days, I am very much into the interface designer. It is a live saver, but it still does not give me what I want. I have 150 odd records per student and 50 students, so to compare 3 to 5 students, I need to do a lot of eye gymnastics. I can filter the students, which I do, but the records start getting too spread out and also it does not permit a side by side comparison.

@kuovonne Pivot table is the first thing I did. The extension is not so powerful. so I exported to XLS and did it there. That is a way, but I would love to have it right there and also able to modify it when I am seeing it in a tabular matrix form. No, the matrix extension is not helpfull here either. There is one fundamental issue in general with the Pivot table I found is it expects you to do some calculation, sum, count, average - something. I just want to see the orignal values.

Looking at your example tables it feels like you just want to have the same data presented vertically/rows (as opposed to the original horizontal/column presentation).

Isn’t the data the same?

Yes, Data is the same but presentation is like you mentioned, transposing some values from record to a field. If it can also be used to edit data, that would be an icing on the cake