Bug 170521 - Merge mail saving or printing doesn't work across pagebreaks
Summary: Merge mail saving or printing doesn't work across pagebreaks
Status: UNCONFIRMED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: All Windows (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2026-01-28 23:43 UTC by Stefano
Modified: 2026-01-29 01:21 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
The file created with "save merged files" showing the bug (23.00 KB, application/vnd.oasis.opendocument.text)
2026-01-29 01:03 UTC, Stefano
Details
The main file containing mail merge fields used to create the bug (24.50 KB, application/vnd.oasis.opendocument.text)
2026-01-29 01:16 UTC, Stefano
Details
This is the sample database (as .ods) containing the records (14.50 KB, application/vnd.oasis.opendocument.spreadsheet)
2026-01-29 01:20 UTC, Stefano
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Stefano 2026-01-28 23:43:44 UTC
Description:
I often use the "merge mail" functions to add codes from a database on every page of my documents for identification of the each copy.

I've notice that, if there is break and a change of page style at some point in the document, when I try to print or save the series of documents, the fields containing the records are only updated in the initial section but they are not in the following sections: the first record is maintained on every copy. If I manually click on the arrows of the merge mail toolbar, though, the records are updated correctly across the whole document. 
So I'm forced to click "next" and save a copy one by one every time I use different page style in the same document, which is frustrating and time consuming.

This bug has been present since I first started using LibreOffice, about 10 years ago.

Steps to Reproduce:
1.Create a document in Writer with a page break with a different style of page after the break, so that headers and footers can be set independently before and after.
2. Create a database containing a number of records.
3. Insert two or more "mail merge field" using the database as header or footer both before and after the break of the page.
4. Save or print mail merged documents from the mail merge toolbar, spanning several records.
 

Actual Results:
All saved or printed documents only contain the first record after the page break.

Expected Results:
The fields should be upadated across the whole document.


Reproducible: Always


User Profile Reset: Yes

Additional Info:
Version: 25.2.3.2 (X86_64) / LibreOffice Community
Build ID: bbb074479178df812d175f709636b368952c2ce3
CPU threads: 12; OS: Windows 11 X86_64 (10.0 build 26100); UI render: Skia/Raster; VCL: win
Locale: it-IT (it_IT); UI: it-IT
Calc: CL threaded
Comment 1 m_a_riosv 2026-01-29 00:19:31 UTC
Please attach a sample files, reduce the size as much as possible without private information, and paste the information in Menu/Help/About LibreOffice, there is a copy icon.
Comment 2 Stefano 2026-01-29 01:03:22 UTC
Created attachment 205246 [details]
The file created with "save merged files" showing the bug

Here a sample file displaying the bug.

Version: 25.2.3.2 (X86_64) / LibreOffice Community
Build ID: bbb074479178df812d175f709636b368952c2ce3
CPU threads: 12; OS: Windows 11 X86_64 (10.0 build 26100); UI render: Skia/Raster; VCL: win
Locale: it-IT (it_IT); UI: it-IT
Calc: CL threaded
Comment 3 Stefano 2026-01-29 01:16:41 UTC
Created attachment 205247 [details]
The main file containing mail merge fields used to create the bug

This is the file used to create merged file with the bug.
Comment 4 Stefano 2026-01-29 01:20:08 UTC
Created attachment 205248 [details]
This is the sample database (as .ods) containing the records

This file contains the records referenced by the fields of the "master" odt file.

Version: 25.2.3.2 (X86_64) / LibreOffice Community
Build ID: bbb074479178df812d175f709636b368952c2ce3
CPU threads: 12; OS: Windows 11 X86_64 (10.0 build 26100); UI render: Skia/Raster; VCL: win
Locale: it-IT (it_IT); UI: it-IT
Calc: CL threaded
Comment 5 Stefano 2026-01-29 01:21:03 UTC
I've attached all the relevant files.