'Lookup' in Beast Mode
Hi,
I am looking for help to build a beast mode calculation for ColumnA here.
ColumnA does not exist in the data and will be built using Beast Mode. The first three values have to be manually input and the fourth value onwards I need it as a calc as shown. Can someone please help me with this? Please let me know if you have any questions. Thanks in advance.
Answers

Hi @utkarsh I don't believe there is a way to accomplish this in Beast Mode since the calculation for ColumnA is dependent on previous values of the same column. Ordinarily if you needed to reference values in previous rows, I would recommend the LAG function in the Rank & Window ETL tile (https://domohelp.domo.com/hc/enus/articles/360044876094MagicETLTilesAggregate#3.), but those window functions rely on fields that already exist in the data.
I'm curious about how you arrived at the first three values of ColumnA. Is there a logic there that you could potentially replicate in this dataset?
0 
Hi @MichelleH thanks for your response. The logic is tough to explain here, but for now if we just assume the first three values exist in the data using the following calc, can we build the next part of logic where we can reference the values from the same column?
CASE when
`Date` = '1/1/2022' then '208' when
`Date` = '2/1/2022' then '197' when
`Date` = '3/1/2022' then '192' else
'Null' end
0 
@utkarsh please articulate in business language what you are trying to accomplish. @MichelleH is correct, you can probably accomplish what you need using Window functions (the LAG() function) in particular, but to assess whether it would always be appropriate to use LAG it's important to understand your use case.
Jae Wilson
Check out my 🎥 Domo Training YouTube Channel 👨💻
**Say "Thanks" by clicking the ❤️ in the post that helped you.
**Please mark the post that solves your problem by clicking on "Accept as Solution"2
Categories
 7.4K All Categories
 13 Getting Started in the Community
 150 Beastmode & Analytics
 1.8K Data Platform & Data Science
 54 Domo Everywhere
 2K Charting
 1K Ideas Exchange
 905 Connectors
 239 Workbench
 343 APIs
 77 Apps
 19 Governance & Productivity
 237 Use Cases & Best Practices
 50 News
 473 Onboarding
 573 日本支部