Unfortunately we don’t have the same functionality as IFMISSINGORNULL in the mobile query feature (I think you might be the first person to ask about it). I don’t think there is a great way to do to this, so you’ll probably have to resort to post-query ordering if that is an option. @jens Do you have a different suggestion?
I also don’t know what the double pipe operator does. Is it a concat?
Unfortunately, I am wanting to use the Limit functionality, so I guess I’ll have to forego that and grab everything from the database first for my sorting.
Is there any way to do conditional testing in a condition?
If CBL exposed the JSON query syntax as an option for creating a query (which I’m strongly in favor of) then you could drop down to that; but unfortunately it doesn’t. I don’t know of any workaround.