Bug 95251 - Mail merge changes orientation after first page
Summary: Mail merge changes orientation after first page
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Printing and PDF export (show other bugs)
Version:
(earliest affected)
5.0.1.2 release
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard: target:5.3.0 target:5.2.1
Keywords:
Depends on:
Blocks:
 
Reported: 2015-10-22 10:01 UTC by Carlo
Modified: 2017-04-17 13:14 UTC (History)
5 users (show)

See Also:
Crash report or crash signature:


Attachments
to be printed file (9.71 KB, application/vnd.oasis.opendocument.spreadsheet)
2015-10-26 10:11 UTC, Carlo
Details
source file (10.22 KB, application/vnd.oasis.opendocument.text)
2015-10-26 10:11 UTC, Carlo
Details
database created by mailmerge (1.74 KB, application/vnd.oasis.opendocument.database)
2015-10-26 10:11 UTC, Carlo
Details
CUPS_PDF printer (14.32 KB, application/download)
2015-10-28 17:09 UTC, Carlo
Details
file printing (15.08 KB, application/download)
2015-10-28 17:30 UTC, Carlo
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Carlo 2015-10-22 10:01:10 UTC
hi all
i am suffering a sever halt in my office productivity:
i often need to print names, addresses, etc on envelopes, and i do it by printing a series (not sure how in english that would be: just writer picks data from a database and prints x envelopes, roughly 25x12 cm each)
it's a month (i guess from latest update) that whenever i start such a series the first envelope is printed correctly, while next ones would be printed in landscape format rather than portrait.
hope i've been clear
i'm running debian stretch, and libreoffice version should be 1.5.0.2-1
i've tried to update to sid libreoffice as well (1:5.0.3~rc1-2) but the outcome is the very same
i'm using an MFP M177 FW by HP

Please help i'm desperate
Comment 1 Buovjaga 2015-10-24 16:39:12 UTC
We would need your file, data source and database to test.
You should replace all the real info. For inspiration: https://wiki.documentfoundation.org/QA/Bugzilla/Sanitizing_Files_Before_Submission#Sanitize_file_text

Set to NEEDINFO.
Change back to UNCONFIRMED after you have attached the test files.
Comment 2 Carlo 2015-10-26 10:11:09 UTC
Created attachment 119959 [details]
to be printed file

here we go:
brand new file, source and databse
Comment 3 Carlo 2015-10-26 10:11:30 UTC
Created attachment 119960 [details]
source file
Comment 4 Carlo 2015-10-26 10:11:52 UTC
Created attachment 119961 [details]
database created by mailmerge
Comment 5 Buovjaga 2015-10-28 16:49:12 UTC
I tried printing to PDF and it went ok, all were portrait.
Did you try PDF printing? Same error or not?

I did my test by immediately hitting Ctrl-P after opening test buste.odt

Win 7 Pro 64-bit, Version: 5.0.2.2 (x64)
Build ID: 37b43f919e4de5eeaca9b9755ed688758a8251fe
Locale: fi-FI (fi_FI)
Comment 6 Carlo 2015-10-28 17:07:53 UTC
I've tried both to print through cups-pdf printer and by choosing file rather than printer
the second way makes out a perfect pdf
CUPS-PDF prints only the third field

i'm attaching the outcomes
Comment 7 Carlo 2015-10-28 17:09:26 UTC
Created attachment 120049 [details]
CUPS_PDF printer
Comment 8 Carlo 2015-10-28 17:30:26 UTC
Created attachment 120050 [details]
file printing
Comment 9 Carlo 2015-10-28 17:31:59 UTC
i've just uploaded 2 siles:
one is obtained by using CUPS_PDF printing and it's oddly printing 3rd letter only

second file (test buste2.pdf) is obtained selecting file rather than printing on the mail merge printing dialogue
Comment 10 Carlo 2015-10-28 17:33:40 UTC
sorry for repeating myself: i had issues with the site and i couldn't imagine message was successfully uploaded as well
Comment 11 Carlo 2015-10-30 15:03:45 UTC
maybe i've found a wayaround:

i should print the mailmerge to an idt file and then print it: it seems to be working, while printing to pdf would make a mess with paper size and printing mailmerge directly would keep rotating paper format after the first page (which wouldn't be too bad if my printer accepted such a large paper format..)
Comment 12 Carlo 2015-10-30 15:11:08 UTC
Wayround is bugged as well:
not sure why but out of 6 pages it printed 3..
and i have difficultires in printing the remaining pages as well

sorry to be a burden
Comment 13 Carlo 2016-03-03 09:50:21 UTC
little update:
now printing to file works, and when i tell printer to print the printed file it's working very good
still libreoffice would reverse landscape to portrait when printing straightly from  mail merge though
Comment 14 Carlo 2016-03-22 12:16:18 UTC
I've just formatted my debian and deleted folders like .libreoffice, .hplip and .cups in my home partition;
i still have the very same issue with mailmerge (if i have to print landscape mode only the first mailmerge print would work and the other ones go portrait)
moreover if i press f4 to show the contents for mailmerge i cannot drag and drop the column title in order to add mailmerge content to the documents but i can do it only from insert --> field command
sorry to bother but it's really getting annoying 

i've tried to start libreoffice from terminal as well, but all iget is glibc errors which i do not think are related to my issue
Comment 15 Buovjaga 2016-03-22 12:25:35 UTC
(In reply to Carlo from comment #14)
> I've just formatted my debian and deleted folders like .libreoffice, .hplip
> and .cups in my home partition;
> i still have the very same issue with mailmerge (if i have to print
> landscape mode only the first mailmerge print would work and the other ones
> go portrait)
> moreover if i press f4 to show the contents for mailmerge i cannot drag and
> drop the column title in order to add mailmerge content to the documents but
> i can do it only from insert --> field command
> sorry to bother but it's really getting annoying 
> 
> i've tried to start libreoffice from terminal as well, but all iget is glibc
> errors which i do not think are related to my issue

Please use a newer version. There was bug 92037 about dragging, but it was fixed. Please use 5.1.x.
Comment 16 Carlo 2016-03-22 17:00:31 UTC
hi
when i inquiry libreoffice it tells me it's
"Versione: 5.1.1.3
Build ID: 1:5.1.1-1
Thread CPU: 1; Versione SO: Linux 4.4; Resa interfaccia: predefinito; 
Versione locale: it-IT (it_IT.UTF-8)"

maybe i should wait for the next version to be available?
Comment 17 Buovjaga 2016-03-22 17:06:12 UTC
The drag and drop bug should be fixed in your version.
Comment 18 Carlo 2016-03-24 11:45:23 UTC
Moreover this libreoffice is crashing everytime i try to select a personalised theme as well
sorry to bother
Comment 19 Carlo 2016-05-21 12:39:55 UTC
Little Update 2:

i've tried Linux Mint Ubuntu 64 bit form live:
i have downloaded the latest hplip drivers:
Printer worked, drag and drop from the database fields worked, but mailmerge with landscape would always turn portrait after the first print...
Comment 20 Alex Thurgood 2016-06-15 10:55:40 UTC
Sounds like the reporter is encountering the same behaviour as bug 38481
Comment 21 Carlo 2016-06-15 14:40:23 UTC
yup, same as bug 38481 and bug 37952
Comment 22 Michael 2016-06-17 20:47:42 UTC
I don't believe this is the same as bug 38481 and bug 37952. Unlike in those bugs, a single envelope (or other landscape document) is printing fine, and mail merging a single record prints fine. It is only when more than one record is being merged that you see all successive documents printed portrait, and for envelopes that often results in a blank envelope. I just ran across this bug in 5.1.3.2 as currently shipped with Ubuntu 16.04. It is a show stopper that forced our receptionist to return to Ubuntu 14.04 until it can be fixed.
Comment 23 Carlo 2016-06-17 22:03:39 UTC
Uh... i didn't think about that

however i'm really tempted to face a severe downgrade as well.. it's becoming really annoying to mailmerge on a file on every source change
Comment 24 Commit Notification 2016-07-30 15:03:21 UTC
Jan-Marek Glogowski committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=b6a698b093f78dc90836d502db3d0276f335fbfe

tdf#95251 MM just allow print as single document

It will be available in 5.3.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 25 Commit Notification 2016-08-02 15:22:06 UTC
Jan-Marek Glogowski committed a patch related to this issue.
It has been pushed to "libreoffice-5-2":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=498bcdbbb02696c66f9bd093b30c17b9efd1459c&h=libreoffice-5-2

tdf#95251 MM just allow print as single document

It will be available in 5.2.1.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 26 Carlo 2016-08-03 09:24:11 UTC
(In reply to Commit Notification from comment #25)
> Jan-Marek Glogowski committed a patch related to this issue.
> It has been pushed to "libreoffice-5-2":
...
> 
> Affected users are encouraged to test the fix and report feedback.

sorry to ask, but is there any guide on how i can apply the patch?
thank you
Comment 27 Jan-Marek Glogowski 2016-08-04 15:36:31 UTC
(In reply to Carlo from comment #26)
> (In reply to Commit Notification from comment #25)
> > Jan-Marek Glogowski committed a patch related to this issue.
> > It has been pushed to "libreoffice-5-2":
> ...
> > 
> > Affected users are encouraged to test the fix and report feedback.
> 
> sorry to ask, but is there any guide on how i can apply the patch?
> thank you

If you don't plan to learn developing LibreOffice and building your own software, just download the patched version of LO, like stated in previous comments:

(In reply to Commit Notification from comment #25)
> It will be available in 5.2.1.
> 
> The patch should be included in the daily builds available at
> http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
> information about daily builds can be found at:
> http://wiki.documentfoundation.org/Testing_Daily_Builds
Comment 28 Jan-Marek Glogowski 2016-08-04 15:37:39 UTC
Otherwise have a look at https://wiki.documentfoundation.org/Development
Comment 29 Xisco Faulí 2016-09-15 22:48:13 UTC
Hello,
Is this bug fixed?
If so, could you please close it as RESOLVED FIXED?
Comment 30 Michael 2017-04-17 13:14:38 UTC
I can confirm this has been working since release 5.2.1.