View Single Post
Old 01-27-2022, 03:03 AM   #1
ownedbycats
Custom User Title
ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.
 
ownedbycats's Avatar
 
Posts: 10,998
Karma: 75337983
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
Undefined sorting in composite columns

I wanted to fix some stubborn multi-column sorting (e.g. currently-reading books getting separated depending on whether or not they were on the TBR list) and the best way I figured to do it was to combine #currentlyreading and #onreadinglist:

Code:
program:
	if $$#percentread >=# 1 && $$#percentread <=# 99
	then 'Currently Reading'

	elif $#readinglist == 'To Be Read' && $$#percentread ==# 0
	then 'To Be Read'

	else 'zzz'

	fi
But is there a more elegant way to make undefined values sort to the bottom when using A-Z sort?

Last edited by ownedbycats; 01-27-2022 at 03:53 AM.
ownedbycats is offline   Reply With Quote