numbers question

Joined
Dec 28, 2017
Messages
50
Reaction score
0
Points
6
hi
is it possible in numbers to sort a file, make changes to the data, then undo the sort and without loosing the changes to the data?

jmickeyg
 

Raz0rEdge

Well-known member
Staff member
Moderator
Joined
Jul 17, 2009
Messages
15,762
Reaction score
2,100
Points
113
Location
MA
Your Mac's Specs
2022 Mac Studio M1 Max, 2023 M2 MBA
Of course, sorting has nothing to do with data changes. Same goes for filtering or reordering the rows. Totally separate operations.
 
Joined
Jan 1, 2009
Messages
15,494
Reaction score
3,853
Points
113
Location
Winchester, VA
Your Mac's Specs
MBP 16" 2023 (M3 Pro), iPhone 15 Pro, plus ATVs, AWatch, MacMinis (multiple)
hi
is it possible in numbers to sort a file, make changes to the data, then undo the sort and without loosing the changes to the data?

jmickeyg
Anything is possible. What, exactly, are you trying to do? What does "sort a file" mean? Files are things used to store data, do you mean you want to sort a spreadsheet? Multiple tabs on a spreadsheet in a file? What? If you can be a bit more specific, you'll get a more helpful suggestion, I think. I will say that I don't think you can change values on which you have sorted and undo it, but there may be other ways to skin that cat if you want to do that. I just tried to undo a sort and as soon as a value changed the undo sort option went away. But tell us what you want to do and we can see if a workaround is available.
 
OP
J
Joined
Dec 28, 2017
Messages
50
Reaction score
0
Points
6
I sorted a file to put column b in alphabetic order. Deleted rows that had column b blank . Ow want to put the file back into original order without the blank column b rows
Mac more sense?
Jmickeyg
 

Raz0rEdge

Well-known member
Staff member
Moderator
Joined
Jul 17, 2009
Messages
15,762
Reaction score
2,100
Points
113
Location
MA
Your Mac's Specs
2022 Mac Studio M1 Max, 2023 M2 MBA
Yes that should work totally fine. Make note of the total number of rows in your file, sort the column you want, delete the rows you don't want, then remove the sort to return to "natural" sort and you should see (original - deleted) lines now.
 
OP
J
Joined
Dec 28, 2017
Messages
50
Reaction score
0
Points
6
once you delete the rows the only option under edit is undo delete. How do you remove the sort without doing remove delete first?
jmickeyg
 

Raz0rEdge

Well-known member
Staff member
Moderator
Joined
Jul 17, 2009
Messages
15,762
Reaction score
2,100
Points
113
Location
MA
Your Mac's Specs
2022 Mac Studio M1 Max, 2023 M2 MBA
A picture is worth a thousand words. If these are the things you are doing, show us your pictures.

Initial state
Screen Shot 2020-01-08 at 9.06.20 AM.png

Sorted column B Ascending
Screen Shot 2020-01-08 at 9.06.25 AM.png

Deleted rows where column B is blank and resorted back to column A Ascending
Screen Shot 2020-01-08 at 9.06.40 AM.png
 
OP
J
Joined
Dec 28, 2017
Messages
50
Reaction score
0
Points
6
and how exactly did you restore back to column A setting? its not edit/undo. i don't see an option on sort pallette like the off/on button on filters palette. that's the trick that eludes me. i know it will be a forehead flattening moment when i see it.
 

Raz0rEdge

Well-known member
Staff member
Moderator
Joined
Jul 17, 2009
Messages
15,762
Reaction score
2,100
Points
113
Location
MA
Your Mac's Specs
2022 Mac Studio M1 Max, 2023 M2 MBA
I just sorted column A in ascending order.

Turns out once you sort any column, you cannot go back whatever the default sort was before.
 
Joined
Jan 1, 2009
Messages
15,494
Reaction score
3,853
Points
113
Location
Winchester, VA
Your Mac's Specs
MBP 16" 2023 (M3 Pro), iPhone 15 Pro, plus ATVs, AWatch, MacMinis (multiple)
One way to do what you want is to add a column for sorting. In each cell of that column put a number or letter, such that when those numbers/letters are sorted, the table is in the order you want. Now you can sort on the column with the blanks you want to delete, delete the rows, then sort again on the column with the numbers and it will be put back in the order you want. You are correct that there is no "undo" after you edit the table because the table is no longer the same as it was in the original sort. What Ashwin suggested is basically the same thing as what I suggested, except he assumed that the elements in Column A are in sortable order and that was what was wanted. Column A in his example is sorted by date, with just month showing. If you have similar column that can be sorted to put the table back in the original order, you don't need the special column.
 

krs


Joined
Sep 16, 2008
Messages
3,555
Reaction score
610
Points
113
Location
Canada
Maybe I don't understand what jmickeyg's requirement, but it sounds to me that he/she wants to select all the blanks in one column of a spreadsheet and then delete the rows which had the blank cells in that column.
I pretty much only use Excel for my spread sheets, but that type of operation can be done directly in Excel and I would think in Numbers there is an equivalens opration.
In Excel:
Select the column where you want to remove blanks.
Press F5 and click Special
In the Go To Special dialog box, select Blanks and click OK.
Right-click any of the selected blanks, and choose Delete… from the contextual menu:
Select rows and click OK.

That will remove all the rows that had a blank cell in the selected column
 
OP
J
Joined
Dec 28, 2017
Messages
50
Reaction score
0
Points
6
@razoredge my column A is too complex for a simple sort like that . dates : jan for each nam in B then feb each name in B on down to dec. so you would sort leao dog fox for jan than leap dog fox for feb etc.
@ krs : Ill try that in excel in the PC . just usually more comfortable with mac . time to shake it up.
 

krs


Joined
Sep 16, 2008
Messages
3,555
Reaction score
610
Points
113
Location
Canada
I tried this in Excel on my Mac before I posted.
Worked exactly as advertised - the program basically selects all rows where that cell in the selected column is blank and then deletes those rows and keeps the other rows in the same order (but obviously with no blank rows in between.
I think this is what you were after.
Tried to find a similar function in Numbers, but so far have been unsuccessful.

PS: I think it makes more sense to try to delete the rows which have the blank column cells first before doing any sorting.
With sorting one can usually undo the sort, but that is about it.
 

Shop Amazon


Shop for your Apple, Mac, iPhone and other computer products on Amazon.
We are a participant in the Amazon Services LLC Associates Program, an affiliate program designed to provide a means for us to earn fees by linking to Amazon and affiliated sites.
Top