Forum Discussion
Sorting with following items
L z. is right about challenges when you store data that way, but I think there is still an easy solution...
The shop names are not in alphabetical order (and you presumably want them to remain in that order). If you are willing to prefix them with a number (1-Grocer, 2-Wal Mart, 3-Pharmacy) that helps a lot. Then, you just need a new column (which can be hidden, or at least not included in the print area) with a formula that combines cell values for sorting purposes (shown here for row 1 only):
=LOOKUP(2,1/(COUNTIF(A$1:A1,">"&A$1:A1&CHAR(7))=0),A$1:A1) & B1
Copy (drag) that formula down to the remaining data cells in that column.
So then you'll have...
| 1-Grocer | 1-Grocer | |
| lollipop | 1-Grocerlollipop | |
| lollipop | 1-Grocerlollipop | |
| oh, lolli… | 1-Groceroh, lolli… | |
| 2-Wal Mart | 2-Wal Mart | |
| lime powder | 2-Wal Martlime powder | |
| coconut oil | 2-Wal Martcoconut oil | |
| gravy boat | 2-Wal Martgravy boat | |
| 3-Pharmacy | 3-Pharmacy | |
| Love Potion No. 9 | 3-PharmacyLove Potion No. 9 | |
| Brylcreem | 3-PharmacyBrylcreem |
[hoping this comes out OK; the preview function complains about an error in the HTML it generated]
Sort all the rows on (ascending) values in the new column, but only select columns A & B for printing.
SnowMan55 Thanks Snow Man!
That would be a LOT of work for my 1500+ entries. Easier to cut and paste by store. But thanks for the thoughts.