Sorting Children by Date of Birth

Windows 10
New to Gramps. Please excuse if this issue has already been addressed somewhere. Children/Descendents are not being displayed in order of ‘Date of Birth’. They seem to be displayed in the order they were entered into the database. Can these be re-sorted somehow, or is there a parameter to set?

You are correct, by default, the children are in the order of the record creation.

But you can move them up or mass re-sort the children in a database. (I can’t recommend the sorting tool. In my database, I had lists of Children in their birth order but without any dates. Then I might find dates for 1 or 2… but not the others. The names where tool didn’t have any references would be pushed (out of order) to the end.

For how to re-order them, overriding the order of creation, see the data entry wiki section after the Tip for Children

The same techniques can be used to re-order parent families, spouses, alternate names… and so forth.

I’m curious how others feel, but for me it would be nice to have Gramps do age-sorting automatically. A checkbox pref could be used to turn it on.

I would prefer to NOT have an automatic sort function. There are too many exceptions (no known dates) in my database so any setting would have to be an opt in functionality.

When I first migrated to Gramps I used the Sort Events tool. Big mistake. Too many events like Burial or Military Service that had no date information were sorted as the first events before their birth.

There is already the Sort Children tool which should be enough functionality. I have the two tools Hidden in the Plugin Manager.

As a general rule, I would think that a program like Gramps should not be manipulating the data without a positive action by the user.


This is why I suggested a preference. I expected gramps to certain things by date. It doesn’t.

I also wouldn’t call sorting “manipulating”.

For doing what ? This is too complicated because may people enter children without knowledge of their birth date.

Why ? No, they are sorted by default by entry date. You can always sort them manually.

Maybe a poor choice of words. But the bottom line, Gramps should not perform a data entry operation without a positive action by the user.

Using the sort order of children as an example, I was an exchange student while in high school. I have my host family as a second family where I am a child of that family. In that family I have younger brothers but I want myself listed as the last child. I do not want Gramps manipulating the data by automating that sort. And I have other families that involve children not born to a family where the order of children I do not want by birth order.

Thanks for the responses. Very helpful. I had not realized that Gramps lists according to ‘record creation’. Very helpful to know. I’ll explore further, and attempt to change listings in my database manually.

The normal default for flat Lists in Gramps is to sort on the 1st column of the table. In Views (but not editor windows), you can change the order of columns with the Edit Column tab on the Configure view dialog, accessed via a Configure button on that View’s toolbar.

Grouped lists (like the Person & Family Edit windows) sort somewhat differently.

They group & sort on family groupings, then subsort. (I suspect the subsort is by ID, which are created sequentially.) You can still click on the Date column editor and override the default subsort criteria.

The primary (topmost) parents & primary spouse are weighted more heavily for analysis & most graphs.

@SNoiraud, are you confused that someone would expect children to be sorted by birthdate? Isn’t that the obvious way to sort them? It is to me. I expected oldest to youngest, followed by unknown. You might not. Great. Let’s have a checkbox.

I also continue to think that displaying data in a certain sort order has nothing to do doing anything to the underlying data. Not manipulating or operating on it. Just displaying it differently. Maybe gramps does something internally to the database in order to do the sort, but I wouldn’t have expected that. In other words, I’d have expected that when gramps goes to display children in a family, it uses an existing field to sort them. Changing the sort order doesn’t change anything in those records, it just changes something in the display function. Maybe I’m wrong. :slight_smile:

@emyoulation Ooh, boy, gramps did not like it when I tried to move the birth date. I now have three copies of it in that list. Kind of buggy.

I what way did you ‘move the birth date’?

Do you mean you moved the column via the View’s column editor? Or maybe you dragged the row in the Family Editor by grabbing the date? Or maybe you dragged the text from the date field in the Person editor to another field? All those worked (in the Windows port) without duplicating for me. (Except dragging a Text selection… that duplicates into whichever field it was dropped. Although the text chunk Moves when dragged to the Clipboard.)

Maybe you did something else.

There are so many ways of doing most things that you need to be more explicit. Please say where you started the move, what you grabbed, how it was moved and the destination.

If you dragged an Event from the Clipboard to a Person multiple times, you will get multiple instances of that Event where they have the same Shared information. But you can assign different Roles, Reference Notes, Reference Attributes to each instance.

So you could add an Occupation repeatedly and assign Chairman of the Board, President, Lead Investigator to the different instances. (Although I doubt I’d ever use it that way.)

If gramps uses sorting, the sorting provided by the operating system will be used internally. In this case, the events with an Unknown date will always be the first.

To be clear:
An event without a date is not an event. You can always add a date like before, after, between, …
An unknown date is a 0/0/0 date and that is why they will always be sorted before all other dates.

And wouldn’t ‘about’ & ‘before’ dates skew sorting too?

They seem to be converted into a range based on the date settings in Preferences for the sort. So, with ‘about’ = ±50 years, an ‘about 1867’ census-based birthdate sorts as a ‘1817-1917’ date range. Making it auto-sort before a fully-sourced 8Nov1862 birthdate.

It works correctly for me. This is an example for the events view:

1 Like

Now I have to go back a find where the approximations caused unexpected results!

It took me awhile to realize my unexpected results (for that unremembered task) were related to the ±values. But the workaround was temporarily tightening all the dates Preferences to ±1.

Since it seemed to be behavior-by-design, I never took note of the specific case. Instead, I simply adjusted my workflows to anticipate.

about, before, after, from, between have the most effect on age calculations and filters.

The filter date=1950 will return event dates before 2000 and after 1900 as valid based upon the default 50 year span defined in Preferences.

There are two cases:
1 - The sort for dates. The sort don’t use the default year span define in preferences.
2 - looking for an event date (filtering, …). You are speaking about that. Yes, in this case, the search use the default year span defined in the preferences.

1 Like

I dragged and dropped the Birthdate column in the configure window, as the directions indicate. This created copies instead of moving it. MacOS 10.15.7, gramps 5.1.3.