ContactDownload

Advice and Support Centre

Announcement

Recent posts

Current Status

Price increases 2026

Not commonly downloaded

Latest update for all users

Getting Help With Packing Partner

Registering a user account

#1 25-07-2013 03:57 pm

Kevin
Member
Kevin

Sort By Last Name Doesn't Work

Sorting by last name doesn't work.
It sorts on the second name.
So for example: "Mr Simon Jones" is sorted alphabetically on the S of Simon, not the J of Jones.
It's picking up the Mr (or Mrs or Dr or whatever) as the first name and the second name after that as the surname, (impolite comment removed-Admin)

When checking off 100's of orders this is really annoying as the list is all over the place and not in true last name order.

I'm using version 1.3.20.7

Last edited by Kevin (25-07-2013 03:59 pm)

Offline

#2 25-07-2013 05:57 pm

Andrew
Admin
Andrew

Re: Sort By Last Name Doesn't Work

Sorting by last name does work

Sorting does take into account prefixes but where the first name is not a letter it is impossible to tell if 'Mr Simon Jones' is a first and last name or a double-barrelled last name. If the name were 'Mr S Jones' it would be sorted by J not S.

We will take a look but I doubt there is much that can be done to change the behaviour effectively for every case.

Andrew
 

Offline

#3 25-07-2013 06:46 pm

Kevin
Member
Kevin

Re: Sort By Last Name Doesn't Work

Ok, well what about one I have who's name is 'L B Rana'.

Her name definitely isn't double-barrelled (usually denoted by a hyphen) but still sorts under B not R.

Anyone using a middle name, whether initial or full also fails the sort on last name.

Surely it makes more sense to sort the last name and assume it is the last name than think every name more than two words is double barrelled??
 
I also have lots of names that are a prefix (MR, MRS, etc), followed by a single letter and then a last name which sort on the single letter, not the last name. I can provide screen shots if required?

Last edited by Kevin (25-07-2013 06:52 pm)

Offline

#4 25-07-2013 06:51 pm

Andrew
Admin
Andrew

Re: Sort By Last Name Doesn't Work

We will look into this and see if it can be improved.

Can I please ask you not to be quite so confrontational in your posting, the objective here is to help users, not vent frustration.

Andrew

Offline

#5 25-07-2013 06:54 pm

Kevin
Member
Kevin

Re: Sort By Last Name Doesn't Work

Sorry you see it as confrontational. The problem of the written word over spoken. I don't mean to come across as confrontational. It's just that sorting is one of the most basic and simplest things to program so I can't understand why it isn't done. Sorting by last name should surely mean that, sort on the last name?

Last edited by Kevin (25-07-2013 06:55 pm)

Offline

#6 25-07-2013 06:59 pm

Andrew
Admin
Andrew

Re: Sort By Last Name Doesn't Work

Sure, sorting is simple: http://en.wikipedia.org/wiki/Sorting_al … algorithms

But I will see why initial letters aren't sorting properly.

Andrew

Offline

#7 25-07-2013 07:50 pm

Kevin
Member
Kevin

Re: Sort By Last Name Doesn't Work

Have been a programmer for 20+ years and sorting is one of the first things you get taught. There's tons of code for sorting algorithms already around on the internet if you need help. :)

Offline

#8 25-07-2013 08:07 pm

Kevin
Member
Kevin

Re: Sort By Last Name Doesn't Work

Just trying to be helpful and not teaching you to suck eggs.......

Having no idea what programming language you are using I'm assuming you have the full name in a string?
If you search the string backwards until you hit a space (putting each letter searched into another string) that new string gives you the last name. Then it's a simple quicksort to put everything into alphabetical last name order. (most programming languages have sort functions).

Offline

#9 25-07-2013 08:15 pm

Andrew
Admin
Andrew

Re: Sort By Last Name Doesn't Work

Simply using the last word of the name wouldn't work. I have just collected a random assortment among which are these that wouldn't work on that basis.

  • Capt Military Man Ret'd

  • Kim Jon Lee Sing

  • John Smith c/o Peter Next Door

  • John Smith (front office)

  • Michael O Connor

  • Daddys Boy Jr

I have made some changes to take into account the examples you have given (and those above). It will be available with the next update (most likely Monday 29th July).

Andrew
 

Offline

#10 25-07-2013 08:26 pm

Kevin
Member
Kevin

Re: Sort By Last Name Doesn't Work

True it wouldn't work on those examples.
In my particular case around 40% are Mr/Mrs/Dr etc with a first name or letter, and a surname. 
Around 15% are first name, middle name or letter and last name.
Less than 1% are like the examples you have given.
The rest are firstname or letter and last name - these sort fine.

Unfortunately it means around 55% of my records currently don't sort correctly.
I get the odd few examples as you have shown but surely it is better to account for the majority of cases rather than the few?

Are my records that unique that I'm the only one that finds this a problem? If they are then I fully understand why it has not been done the way I assumed it should be.

(and thanks for the work you have done so far - it really is appreciated and again, sorry if I came across as confrontational previously)

Last edited by Kevin (25-07-2013 08:28 pm)

Offline

#11 31-07-2013 12:38 pm

Andrew
Admin
Andrew

Re: Sort By Last Name Doesn't Work

You should find an improvement after the update, let me know if you have any more examples that don't fit though.

Edit: This has now been incorporated into the latest release, to install: click here

Andrew

Offline

#12 07-08-2013 09:39 am

Kevin
Member
Kevin

Re: Sort By Last Name Doesn't Work

It's so much better now. Thank you very much for fixing this.

Offline

Board footer