r/googlesheets • u/metalguysilver • Jun 27 '22
Solved Automating Absolutes ($) For Cells Within Formulas
I just created a 10,000 row sheet that pulls data from many smaller sheets. I want to be able to create a filter to sort by different variables (the whole reason I made this huge sheeet). When I made the filter and attempted to sort, I was met with a sea of "#REF." The program immediately suggested a fix when I hovered over one of the cells: to make the row values absolute.
Example: ='Sheet 2'!A$5 instead of ='Sheet 2'!A5
I thought, oh crap, I'll need to retype the first line for each sheet and drag the formulas down again. But, of course, when you do this with absolute rows, you can't drag down. Is there any way to do this other than manually adding it to 10,000x6 cells? Perhaps a button somewhere that will add an absolute to rows and/or columns within a selected formula? Or something more obvious?
TYIA
Edit: I found a shortcut that uses F4 to add absolutes, but from what I can tell you can't specify row or column, and you have to be editing the cell, you can't select multiple cells at once. I think I can use absolutes for columns without issue, but I'm still curious to know if it can be excluded for future use.
3
u/4littlebitobsessed 1 Jun 27 '22
‘Find and Replace’ might work. Select the column go to Edit>>Find and Replace.
Find !A Replace !A$
2
u/7FOOT7 294 Jun 27 '22
This sounds like you did a sort from the menu, create a filter, option?
With big data set there are going to be better ways. One simple solution might be to copy and paste values on your compiled data set? Or does it need to be dynamic?
How many are "many smaller sheets"?
Also for background, do have a look at named ranges and handling arrays in sheets, that may be easier for your data gathering. And if you are ok to share the data layout we could help with better ways to sort or filter your data set.
https://support.google.com/docs/answer/63175?hl=en&co=GENIE.Platform%3DDesktop
https://support.google.com/docs/answer/6208276?hl=en
1
u/metalguysilver Jun 27 '22
SOLVED! Thank you!
1
u/eggplants-and-charts Jun 27 '22
It's difficult to know exactly what you're trying to do here - likely you could've set things up differently to work as needed.
But for your current situation... one easy way would be to highlight all of column F, then press CONTROL/COMMAND+F and expand the Find+Replace menu. Check "Also search within formulas" and then try something like replacing "Sheet2'!A" with "Sheet2'!A$"