Bug 157691 - MailMerge creates bigger PDF when number of recipients increases (repeated outline headings from footer; extra hidden images)
Summary: MailMerge creates bigger PDF when number of recipients increases (repeated ou...
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Mail-Merge
  Show dependency treegraph
 
Reported: 2023-10-10 20:20 UTC by Reinhard Klapproth
Modified: 2023-10-25 14:23 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
zip-file containing used odt-file and generated pdf-files (556.83 KB, application/zip)
2023-10-10 20:30 UTC, Reinhard Klapproth
Details
test kit: ODT + ODS (316.93 KB, application/zip)
2023-10-25 14:23 UTC, Stéphane Guillou (stragu)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Reinhard Klapproth 2023-10-10 20:20:09 UTC
Description:
Sending e-mails via MailMerge as a pdf-file produces a pdf-attachment of around 120 K when the number of sent mails is low (< 10). When the list of mail addresses is larger (> 200) MailMerge enlarges the pdf-file to 1.2 M each. Mailmerging the same address list for saving on hard drive produces normal sized pdf-files. 

Steps to Reproduce:
1. Load odt-file using Libreoffice Writer
2. Tools->Mail Merge Wizard -> 
Starting Document: Current
Document Type: Email Message
-> Next Step -> Finish 
3. Press Icon "Send merged document as email" of toolbar Mailmerge
4. Enter "To", "Subject", "Send as": pdf
5. "Copy To"-dialogue: CC: no entry, BCC: enter an e-mail-address
6. "Properties"-dialogue: "Write your message here": Enter message and press "OK"
7. Press "Send Documents"

Actual Results:
Sent pdf-file of size 1.2 MB to every e-mail-address.

Expected Results:
Sent pdf-file of size 120 KB to every e-mail-address.


Reproducible: Always


User Profile Reset: No

Additional Info:
Version: 7.6.2.1 (X86_64) / LibreOffice Community
Build ID: 9d0b4c0791fc17bc4181a67fd90c5aaed576d1c0
CPU threads: 12; OS: Linux 6.2; UI render: default; VCL: gtk3
Locale: de-DE (de_DE.UTF-8); UI: de-DE
Calc: threaded

OS: Ubuntu 22.04.3 LTS
Comment 1 Reinhard Klapproth 2023-10-10 20:30:42 UTC
Created attachment 190123 [details]
zip-file containing used odt-file and generated pdf-files

zip-file contains odt-file used for mailmerge
pdf-file no.1 generated by mailmerging 1 address
pdf-file no.2 generated by mailmerging > 200 addresses
Comment 2 Stéphane Guillou (stragu) 2023-10-25 14:18:51 UTC
One difference between the two provided PDFs is that 7 of the "headings" are repeated in the outline many times in the large PDF (the 7 headings in the footer).

Reproduced in OOo 3.3 and:

Version: 7.6.2.1 (X86_64) / LibreOffice Community
Build ID: 56f7684011345957bbf33a7ee678afaf4d2ba333
CPU threads: 8; OS: Linux 5.15; UI render: default; VCL: gtk3
Locale: en-AU (en_AU.UTF-8); UI: en-US
Calc: threaded

I can see the issue in both mailmerged PDFs and ODTs saved to disk, so no need to email.

In mailmerged ODTs, I can see duplicated "hidden" graphics in the navigator (although it does not make the file size increase).

In mailmerged PDFs however, the size gets bigger as the number of recipients increases. For example, with OOo 3.3: 103 bk for 3 recipients vs 150 kb for 21 recipients
I notice in the opened PDF that the footer headings are duplicated as many times as there are recipients.
Comment 3 Stéphane Guillou (stragu) 2023-10-25 14:23:59 UTC
Created attachment 190415 [details]
test kit: ODT + ODS

Test with this archive of the original ODT + 1 data source as ODS

1. Open ODT
2. You might have to Edit > Exchange the database to the attached ODS
3. In the mail merge toolbar: Save Merged Documents
4. Save as individual documents > Save documents > PDF
5. Reduce ODS to only 2 or 3 recipients, then repeat steps 3-4
6. Compare size of outputs

Result: difference in size; repeated headings in PDF outline