Forum Discussion

JohannesM's avatar
JohannesM
Helper I
4 years ago
Solved

Generate table with years and calculated values

I have a table of items with column A containing item ID, column B containing the items lifespan, column C containing the year each table became active, and lastly column D with the items purchase va...
  • JohannesM's avatar
    JohannesM
    4 years ago

    Hi Xiaoxin,
    I actually ended up doing something close to that. I first duplicated the table I needed and then removed some columns to get the leanest table possible. I then created a new table with one column of years from 1970 to 2070 and then simply generated a new table with generate(duplicatedTable, newTable) to get a table with IDs and years. 
    Only thing left was to create a if-statement to calculate the value I needed. It is a table with many rows but it doesn't seem to be a problem using if-logic so that's great.
    Mabye I will try your solution if mine runs in to issues when we add even more rows to the modell, so thanks 😃

    Br
    Johannes