Jump to content

Wikipedia:Reference desk/Archives/Computing/2018 May 14

From Wikipedia, the free encyclopedia
Computing desk
< May 13 << Apr | May | Jun >> May 15 >
Welcome to the Wikipedia Computing Reference Desk Archives
The page you are currently viewing is a transcluded archive page. While you can leave answers for any questions shown below, please ask new questions on one of the current reference desk pages.


May 14

[edit]

Sorting special characters in Excel

[edit]

In Finnish language the letters ä and ö are considered to be independent letters, not just variations of a and o. When using the sorting function in Excel, Excel doesn't recognize them as different letters from a and o, even though the language is set to Finnish. Even when using customized sorting order, Excel doesn't seem to recognize the difference. Is there any way to make Excel recognize letters with diacritics? — Preceding unsigned comment added by 84.251.95.54 (talk) 19:20, 14 May 2018 (UTC)[reply]

Not sure off the top of my head, as my Excel is rusty. What you're looking for is called "collation order", if you can search the online help. Now in SQL Server, you can do this by setting the collation to Finnish_Swedish_CI_AS. Although the languages are so different, they both have this same sorting behaviour.
Now, have Microsoft made the behaviour in Excel standard with what they've done for SQL? Not sure, but that would be where to start looking. As I recall, Excel was very limited here - it had simple ASCII and binary modes, but the binary was only in the local codepage, usually Windows-1252, unless you've set it for the whole of the Windows install. Even in Excel VBA and the StrComp() function it had this limitation. You can start using Windows API functions like CompareStringW() from VBA, but that's complicated.
One the whole, I'd bounce problems like this in and out of a database server to do the sorting. Now that is pretty easy from Excel (provided that such services are available to you). Most of my big Excel spreadsheets are database-backed anyway. You might even be able to do this with good old Access [sic] and the Jet Engine, running on a local desktop. Andy Dingley (talk) 08:26, 15 May 2018 (UTC)[reply]