You can make a difference in the Apple Support Community!

When you sign up with your Apple Account, you can provide valuable feedback to other community members by upvoting helpful replies and User Tips.

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Apple Numbers: On a separate sheet, list 20 most recent entries from main database (dynamic update)

Hello,

I have a large record collection in a database. What I would like is to have the 20 most recent entries listed on a separate sheet, and have it dynamically update. I do have a “date added” field on the main database. I just don’t want to have to continually resort my table by this column. I want this info displayed on a separate sheet, and I want it to dynamically update whenever I add new titles to the main database. Is this even possible?


thank you,

Jonathan

MacBook Pro 16″

Posted on Aug 6, 2023 12:50 PM

Reply
Question marked as Top-ranking reply

Posted on Aug 6, 2023 4:58 PM

If you only ever add just one record per date then you can do something like this:




In D2 of the "most recently added" table, filled down:


=LARGE('Data -1'::D,ROW()−1)


In A2, filled right to C2, and then down:


=LARGE('Data -1'::D,ROW()−1)


If you may add more than one record on the same date then you could add "index" columns, which you could then hide:




In column E2 of the data table, filled down:


=D2+ROW()


In column E2 of the recently added, filled down:


=LARGE('Data - 2'::$E,ROW()−1)


In column A2, filled right to D2, and down:


=XLOOKUP($E2,'Data - 2'::$E,'Data - 2'::A)


You can try this, but in the end you may find the powerful built-in sorting and filtering features in Numbers are easier!


SG


Similar questions

9 replies
Question marked as Top-ranking reply

Aug 6, 2023 4:58 PM in response to Jonathan Christensen

If you only ever add just one record per date then you can do something like this:




In D2 of the "most recently added" table, filled down:


=LARGE('Data -1'::D,ROW()−1)


In A2, filled right to C2, and then down:


=LARGE('Data -1'::D,ROW()−1)


If you may add more than one record on the same date then you could add "index" columns, which you could then hide:




In column E2 of the data table, filled down:


=D2+ROW()


In column E2 of the recently added, filled down:


=LARGE('Data - 2'::$E,ROW()−1)


In column A2, filled right to D2, and down:


=XLOOKUP($E2,'Data - 2'::$E,'Data - 2'::A)


You can try this, but in the end you may find the powerful built-in sorting and filtering features in Numbers are easier!


SG


Aug 7, 2023 7:34 AM in response to Jonathan Christensen

Your formula in Y2 refers correctly to $Y, an entire column


Your formula in Y3 refers to Y3, a cell instead of an entire column.


So something went wrong.


Once you have the correct formula in Y2, you need to "Autofill" that down the column. (I have 21 rows in my example table when including the Header Row).


On the iPad


  1. tap the cell Y2 and the Cell actions button lower right
  2. tap 'Autofill Cells' and drag the bottom edge of the yellow rectangle down the column.


The result is in descending date order.


SG






Aug 7, 2023 5:05 AM in response to Jonathan Christensen

The error message suggests that you don't have a value in X2 the Numbers recognizes as date & time. A date & time value value would be right-aligned by default.


Where are you getting that format? Are you importing it or entering it manually? If entering it you could consider using - instead of . between the year month and day.


You can convert to "true" date & time with something like this:




=SUBSTITUTE(A2,".","-")+0



Or if your region uses , as the decimal separator:


=SUBSTITUTE(A2;".";"-")+0


Adding the 0 coerces the result of SUBSTITUTE from Text to Date & Time


If you are referring to X2 you would of course use X2 in the formula instead of A2.


SG






Aug 7, 2023 6:46 AM in response to SGIII

OK…I have fixed the dates. They were getting converted by a 3rd party application which turned the dashes into periods. Now, I’m running into another problem.


Here’s the formula I’m using

=LARGE('Table 1'::$Y,ROW()−1)

When I apply it to Y2 of the “20 recently added” sheet, it seems to work. But trying to apply it to the next field down gives me this error.



Aug 13, 2023 5:24 AM in response to Jonathan Christensen

Jonathan Christensen wrote:

I then took a step back and got the exact functionality I wanted using a pivot table, and a couple of filtering options.


Yes, that is my experience. Pivot Tables (and Filters) are powerful, flexible, and easy to use. They can prevent hours of fiddling with formulas and extra columns and such. The only drawback: don't forget to "refresh" after adding or changing data in the source table! One click on the refresh icon or a trip to the menu will do that.


SG


Apple Numbers: On a separate sheet, list 20 most recent entries from main database (dynamic update)

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.