[Solved] Sorting by date in a spreadsheet

Discuss the spreadsheet application
Post Reply
cwr1946
Posts: 10
Joined: Sat Sep 25, 2010 1:07 am

[Solved] Sorting by date in a spreadsheet

Post by cwr1946 »

Downloaded a checking account transaction file (.csv), saved as .ods file. Now trying to sort the entries by date. The data in the date column is by m(m)/d(d)/yyyy. How can I sort these entries by calendar date? I've defined the format of that column as date 12/31/1999, but when I sort I get 1/xx/yyyy (ALL January entries by day of month for ALL years) then 10/xx/yyyy (All October entries by day of month for ALL years). How can I get OO to recognize the date and sort correctly?
Last edited by cwr1946 on Sat Sep 04, 2021 9:15 pm, edited 2 times in total.
Open Office 3.2.1 Build 9502; Windows 7 Professional
User avatar
Villeroy
Volunteer
Posts: 31279
Joined: Mon Oct 08, 2007 1:35 am
Location: Germany

Re: Sorting by date in a spreadsheet

Post by Villeroy »

You must not ignore the import options.
Always check the "special numbers" option.
Choose any English locale except USA when importing dd/mm/yyyy dates.
Choose English (USA) when importing mm/dd/yyyy dates.
Once you imported the correct values, you can format them any way you want. Formatting never ever changes a single value. However, correct values can be calculated, filtered and sorted correctly.
Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
User avatar
Zizi64
Volunteer
Posts: 11359
Joined: Wed May 26, 2010 7:55 am
Location: Budapest, Hungary

Re: [Solved] Sorting by date in a spreadsheet

Post by Zizi64 »

How can I get OO to recognize the date and sort correctly?
The real dates are numeric values. Calc can sort the numeric values.
Use the import filter properly for converting the date-like strings (of the .csv file) to numeric type.
Tibor Kovacs, Hungary; LO7.5.8 /Win7-10 x64Prof.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
Post Reply