I am looking for a flexible custom function to be able to cross-join (cartesian product) 2 columns of varying lengths in Google Sheets.
My research so far has led me to ask because:
- using a combination of existing formulas in Sheets either produces some weird artifacts (counting blank cells as values to cross-join) or has limits to how many results it can produce.
To further describe my request:
- It must be able to cross-join 2 columns of ANY length (if one column is longer than the other, I don't want it to utilize blank cells from the shorter one).
- I would love it to be flexible in that I can place it anywhere and use any combination of columns
Sorry for any missing information, it's my first time posting here
Here's an example of some data sets and results I would like to get from this one script:
I've seen many scripts be dependent on the header name and stuff and I would like that not to be the case.