Getting around circular reference in Google Spreadsheet

我的未来我决定 提交于 2019-12-05 02:34:25

From this week, Google Sheets has announced support for exactly this feature. You can now limit the number of iterations for circular references in the spreadsheets settings :-)

On the top menu of a google spreadsheet do the following:

File > Spreadsheet settings

Choose the "Calculation" tab, and change "Iterative calculation" to ON.

Enjoy :D.

PD: I know that this post is too old, but just some days ago I needed a solution to this, and I couldn´t find any.

In excel you can set it to allow circular dependencies and limit the number of iterations they run (usually 1 is the desired result).

I've looked and nothing like that exists in sheets.

user6697023

I know that this post is pretty old, but I saw it while looking to see the applications of a thing.

In sheets, you can use importrange to reference the same sheet and call the desired range. For instance, you can put a formula in B1 that is =A1+1 and in A1 use the formula =importrange(<THIS SHEET ID>,"B1")+1.

You may need to initially put the formula in A2 and then move it up to A1, but it should work.

Doing something like this essentially makes a second counter, which is neat I guess?

Solved with a script that implements the following algorithm

for each row{
   if (A != "" && B == "")
    B = conversionFromA(A);
   if (A == "" && B != "")
    A = conversionFrom(B);}

of course it has it's downsides, (you have to call the script each time you enter new data), but it's the best solution I found

I would add two more columns: data source and data format. Then, the formula in column A would take a value from data source either as is (if the format matches) or converted (if format doesn't match). Same for column B.

I just ran into this while trying to setup formulae to compute metrics from my workout.

Instead of referencing your co-dependent formula cells, use other cells to hold your actual (non-formulaic) data and use the formula cells to show your results. There's no way to get around circular references, unfortunately.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!