Bug 108834 - PIVOTTABLE: empty values filtering works incorrectly for Date type columns
Summary: PIVOTTABLE: empty values filtering works incorrectly for Date type columns
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
4.1.0.4 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: bibisected, regression
Depends on:
Blocks: Pivot-Table
  Show dependency treegraph
 
Reported: 2017-06-28 12:05 UTC by Gabor Kelemen (allotropia)
Modified: 2025-03-03 11:38 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
Sample file (13.45 KB, application/vnd.oasis.opendocument.spreadsheet)
2017-06-28 12:05 UTC, Gabor Kelemen (allotropia)
Details
Only empty values are selected to show in B1 (105.19 KB, image/png)
2017-06-28 12:06 UTC, Gabor Kelemen (allotropia)
Details
There are 9 "Second type" rows with empty values (26.98 KB, image/png)
2017-06-28 12:07 UTC, Gabor Kelemen (allotropia)
Details
I only put 5 rows of "Second type" with empty pwdlastset values to the users sheet (169.60 KB, image/png)
2017-06-28 12:09 UTC, Gabor Kelemen (allotropia)
Details
Test file (15.05 KB, application/vnd.oasis.opendocument.spreadsheet)
2017-06-29 14:29 UTC, m_a_riosv
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Gabor Kelemen (allotropia) 2017-06-28 12:05:26 UTC
Created attachment 134343 [details]
Sample file

Attached spreadsheet contains a simple pivot table with a filter in B1 set to show only the empty values.

The number of values shown after filtering differs from the ones I'd expect.

Of the "Second type" (cell A5) there should be 5 entries on the users sheet, yet Calc shows the value 9 in cell B5.
Clicking on the cell produces a new sheet with the 9 "Second type" rows, of which 4 have a value in the filtered pwdLastSet column.

Similarly for the hidden (empty) type in cell A6 Calc should show 2 in B6, yet it shows 3.

Autofiltering the C and E columns on the users sheet shows correct number of "Second type" and (empty) values where the E column is empty: 5 and 2.
Comment 1 Gabor Kelemen (allotropia) 2017-06-28 12:06:22 UTC
Created attachment 134344 [details]
Only empty values are selected to show in B1
Comment 2 Gabor Kelemen (allotropia) 2017-06-28 12:07:31 UTC
Created attachment 134345 [details]
There are 9 "Second type" rows with empty values
Comment 3 Gabor Kelemen (allotropia) 2017-06-28 12:09:45 UTC
Created attachment 134346 [details]
I only put 5 rows of "Second type" with empty pwdlastset values to the users sheet
Comment 4 m_a_riosv 2017-06-29 14:29:52 UTC
Created attachment 134385 [details]
Test file

Looks it counts not only empty but some other rows.
Visible with the pt organize on other way, attached.
Comment 5 Buovjaga 2017-06-29 18:01:48 UTC Comment hidden (obsolete)
Comment 6 m_a_riosv 2017-06-29 18:23:16 UTC Comment hidden (obsolete)
Comment 7 QA Administrators 2018-10-13 03:14:00 UTC Comment hidden (obsolete)
Comment 8 QA Administrators 2020-11-07 04:11:35 UTC Comment hidden (obsolete)
Comment 9 Gabor Kelemen (allotropia) 2021-03-25 23:26:47 UTC
Still the same in

Version: 7.2.0.0.alpha0+ / LibreOffice Community
Build ID: 5262a9e88037decc26da84e7fa62f2955d4cdb85
CPU threads: 8; OS: Linux 5.4; UI render: default; VCL: gtk3
Locale: hu-HU (hu_HU.UTF-8); UI: en-US
Calc: threaded
Comment 10 QA Administrators 2023-03-26 03:23:25 UTC Comment hidden (obsolete)
Comment 11 Timur 2025-03-03 09:59:55 UTC
Still reproduced in 25.8+.

This is a regression but in a large range:
https://cgit.freedesktop.org/libreoffice/core/log/?qt=range&q=20f2aaced1dabbd62ea516368b85e0e881d42165..3a9e1e71d9a28b2c6bc96757e629b231d2276d9d

This one mentions "filter" - could be checked:
https://cgit.freedesktop.org/libreoffice/core/commit/?id=3d5789d48d6602832abd33268e31afa4080cb87a
author	Ricardo Montania <ricardo@linuxafundo.com.br>	2012-12-12 13:26:57 
committer	Luboš Luňák <l.lunak@suse.cz>	2012-12-13 13:05:33 
commit 3d5789d48d6602832abd33268e31afa4080cb87a (patch)
String removal in filter
Comment 12 Buovjaga 2025-03-03 11:38:26 UTC
(In reply to Timur from comment #11)
> Still reproduced in 25.8+.
> 
> This is a regression but in a large range:
> https://cgit.freedesktop.org/libreoffice/core/log/
> ?qt=range&q=20f2aaced1dabbd62ea516368b85e0e881d42165..
> 3a9e1e71d9a28b2c6bc96757e629b231d2276d9d
> 
> This one mentions "filter" - could be checked:
> https://cgit.freedesktop.org/libreoffice/core/commit/
> ?id=3d5789d48d6602832abd33268e31afa4080cb87a
> author	Ricardo Montania <ricardo@linuxafundo.com.br>	2012-12-12 13:26:57 
> committer	Luboš Luňák <l.lunak@suse.cz>	2012-12-13 13:05:33 
> commit 3d5789d48d6602832abd33268e31afa4080cb87a (patch)
> String removal in filter

That is about XML file handling, though. We can also search with:

git log --stat --pretty=short --graph 20f2aaced1dabbd62ea516368b85e0e881d42165..3a9e1e71d9a28b2c6bc96757e629b231d2276d9d | grep -B 10 -A 10 --color=always "sc/" | less -R

There is this interesting one: 1360b28b477f980a2c58659ffc298d0dd2cda20b
bnc#791706: Support multiple selection in page fields.

This change allows selecting multiple items in page field popups in
pivot table.