Bug 47153 - Form Letter PRINTING: Picture or Draw shape in Page Header suppresses some contents on most pages of particular document
Summary: Form Letter PRINTING: Picture or Draw shape in Page Header suppresses some co...
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
(earliest affected)
3.5.0 release
Hardware: All All
: medium major
Assignee: Not Assigned
Keywords: preBibisect, regression
: 56228 (view as bug list)
Depends on:
Blocks: Mail-Merge
  Show dependency treegraph
Reported: 2012-03-09 07:06 UTC by hc.stoellinger
Modified: 2021-12-04 08:49 UTC (History)
5 users (show)

See Also:
Crash report or crash signature:
Regression By:

Www.Oddza.Net (43 bytes, text/plain)
2012-10-31 20:17 UTC, Odd
Screenshot of dialog from where I have printed (56.20 KB, image/png)
2012-11-05 12:11 UTC, sasha.libreoffice
Print mailmerge dialog screenshot (176.44 KB, image/png)
2012-11-14 10:50 UTC, sasha.libreoffice
blue lines as raster image for placing into header (256 bytes, image/gif)
2012-11-15 13:48 UTC, sasha.libreoffice
simplified test case for serial letters printing bug (13.18 KB, application/vnd.oasis.opendocument.text)
2012-11-15 14:34 UTC, sasha.libreoffice
headerWrong.jpg (66.92 KB, image/jpeg)
2012-12-09 21:18 UTC, hc.stoellinger
test case created from scratch (28.98 KB, application/vnd.oasis.opendocument.text-flat-xml)
2013-04-03 12:09 UTC, sasha.libreoffice

Note You need to log in before you can comment on or make changes to this bug.
Description hc.stoellinger 2012-03-09 07:06:12 UTC
Printing serial letters (writer/Base/MySQL) works o.k. as long as I only print them separately (i.e., I invoke them separately for every database-record). Hoever, when trying to actually print - say - 50 letters in one batch, only the first of them gets printed correctly.

Within the following letters database variables inserted by me get left out consistently. I use ODBC but the same problem also occurs when using the native MySQLConnedtor under LO-Windows-5.3.0.
Comment 1 sasha.libreoffice 2012-05-31 03:57:03 UTC
Thanks for attachment
Please, attach example database and letter, from where this bug can be reproduced.
Comment 2 Odd 2012-10-31 20:17:31 UTC
Created attachment 69371 [details]
Comment 3 hc.stoellinger 2012-11-01 18:02:18 UTC
I am sending you a "Mysqldump" of my database (rainermusik) plus an odt-file from which the bug should be able to be reproduced. I trust you realise that this information has to be treated with strict confidence.

#the database (rainermusik) was dumped on my system with the following command:
mysqldump -p -u username --add-drop-database --opt --single-transaction rainermusik > ~/sysadmin/backups/databases/rainermusik/dbdump121019.sql
#and and can then be restored with the following command:
mysql -u username -p rainermusik < ~/backups/mysql/databases/rainermusik/dbdump121019.sql > ~/backups/mysql/databases/rainermusik/output121019

you will of course have to adapt username and password

In case you need to contact me by phone: +43 664 14 47 642.
H. Stoellinger
Comment 4 sasha.libreoffice 2012-11-02 06:51:42 UTC
Thanks for email. I will try to reproduce this bug in this month.
Alas, I know very little about MySQL. Learning will take some time.
Comment 5 hc.stoellinger 2012-11-02 07:46:46 UTC
Thanks for the prompt reply, Sasha! As I already mentioned, please do call me in case of difficulty setting up the test environment. I actually suspect that this might be a pure LO-Writer problem. Maybe I find the time to extract some data from the view which is the base for the letters, "convert" them to a LO-Calc spreadsheet and try to produce the serial letters. This would then not need ANY connection to MySQL.
Comment 6 sasha.libreoffice 2012-11-05 12:11:58 UTC
Created attachment 69561 [details]
Screenshot of dialog from where I have printed

I have printed 6 merged document from dialog shown on screenshot. Printed without problem. May be I have done something wrong, because can not reproduce this bug.
Please, provide step-by-step instruction how to reproduce this bug. Or create document with screenshots of each step of creating mail-merge and send it to me or attach to bugreport.
Thanks in advance
Comment 7 hc.stoellinger 2012-11-13 14:51:05 UTC
Hello Sasha,
Thanks for looking at my "bug". Actually I am producing the serial letters in a different way, i.e. by just opening the .odt-file and then hitting "print" instead of going through the wizard. LO then comes back with the dialog box that says "Your document contains database fields. Do you want to print a serial letter" (translated from German!). When I then say yes, LO displays a dialog box where I can select the tuples (i.e. records) of the MySQL database. It then prints the first one o.k., while all the rest miss out the information I mentioned before (some database fields as well as graphics).
Comment 8 sasha.libreoffice 2012-11-14 10:50:08 UTC
Created attachment 70062 [details]
Print mailmerge dialog screenshot
Comment 9 sasha.libreoffice 2012-11-14 11:01:20 UTC
Thanks for additional information
I have opened document bugSerialLetter.odt and pressed "Print" button, then answered "Yes". Appeared dialog, shown on screenshot.
I have selected option "File" in area "Output" for more easy testing.
When I selected "Records All", all 142 mails saved to file.
When I selected "Records From 1 to 50", then first 50 mails saved to file.

So, I have another questions:
1. It is correct dialog I have used?
2. It works correctly if save mails to file?
3. It saves to file correctly if selected "File", but prints only one mail letter if selected "Printer"?

Thanks in advance
Comment 10 sasha.libreoffice 2012-11-15 10:08:21 UTC
*** Bug 56228 has been marked as a duplicate of this bug. ***
Comment 11 sasha.libreoffice 2012-11-15 10:25:05 UTC
I have found answers on my questions:
1. Dialog is correct
2. Works correctly if save to file
3. Prints to printer or PS file incorrectly, beginning from 2-th mail some fields is lost. For example we have these lines in original document:


Es freut uns, Dich bei unserem Verein als Unterstützendes Mitglied begrüßen zu dürfen. 

But in PS file we see no such lines (bug seen already in dialog "Print" in preview on left side of it).

reproduced in 3.6.3 on RFR 17 64 bit, installed from rpm from libreoffice.org
Comment 12 sasha.libreoffice 2012-11-15 13:46:47 UTC
Workaround: in header of first page are two blue lines beneath of words Rainermusik Salzburg. Remove them and place, for example, picture from next attachment instead. It will print correctly after this.
Comment 13 sasha.libreoffice 2012-11-15 13:48:00 UTC
Created attachment 70115 [details]
blue lines as raster image for placing into header
Comment 14 sasha.libreoffice 2012-11-15 14:34:59 UTC
Created attachment 70120 [details]
simplified test case for serial letters printing bug

I have created simplified test case which uses internal LO database and has no need in additional database installing.
It demonstrates problem with printing (use previev in "Print" dialog). Only first and last letters are correct. All other have no date and greetings text.
Reproduced in 3.5.7 and 3.6.3 on RFR 64 bit.
What about Windows: there "Print" dialog is not maximizable and it is hard to see something. But it looks like in 3.4.2 this works correctly. But in 3.5.0 it works wrong. Looks like regression.
Comment 15 hc.stoellinger 2012-12-09 21:18:34 UTC
Created attachment 71242 [details]

Coming back to testing my serial letter problem I now notice the following:
Replacing the  2 blue lines drawn using the draw tool by a graphic (as sent to me),
no more text gets left out. However, as you can see from the enclosed jpg-file,
the z-order (stacking) of the graphics is wrong. The orange rectangle should
be above the blue lines. Of course I could fix this by placing a blue-lines
graphic both to the left and to the right of the orange square. However, it
should also work by simply specifying the correct stacking order.
In any case I feel that LO-Writer has a problem with perfectly "legal" lines
drawn using the provided tool...
Thanks for your help.
H. Stoellinger

On Thu, 15 Nov 2012 15:37:01 +0100, <bugzilla-daemon@freedesktop.org> wrote:

> https://bugs.freedesktop.org/show_bug.cgi?id=47153
> sasha.libreoffice@gmail.com changed:
>            What    |Removed                     |Added
> ----------------------------------------------------------------------------
>             Summary|Serial Letters don't print  |Writer mail merge tool:
>                    |correctly                   |Serial Letters don't print
>                    |                            |correctly (see comment 14)
Comment 16 Rainer Bielefeld Retired 2013-04-03 07:31:00 UTC
I see a lot of questions here, mostly what the heck the problem might be, why this is rated as an Extensions bug, ...
A quick test with current Master and Mail merge wizard did not show anything unexpected.
Steps how to reproduce with parallel Dev-installation of  "Version (Build ID: 049ce78144650d92eb6bd73292868f73d37c901) TinderBox: Win-x86@6, Branch:master, Pull Time: 2013-03-29_23:59:42" ENGLISH UI / German Locale on German WIN7 Home Premium (64bit) with LODev/4 Masters User Profile:

1. Open sample document 2012-11-15 14:34 UTC, sasha.libreoffice@gmail.com 
2. Menu 'File -> Print -> Print Form Letter = Yes'
3. Database = Bibliographa -> Table = bibilio (=default) -> Records = All -> 
   Output = Printer' <Ok>
   > Print monitor shows creation of merged document
   > Print preview appears
4. Resize print preview to max, check pages view
   Expected: All Pages with Date info ("Salzburg, 3. April 2013") and 
             "Es freut uns,  bei unserem ..."
   Actual: Date missing on any page except first

Works fine with Menu 'Tools -> Mailmerge'

Deleting both pictures from page header or changing anchor of both ones to "as character" heals the problem - strange!

Same problem when I replace the gifs by a draw line object or a smiley shape.

I see lots of additional effects, also in Mailmerge wizard, what might be related or not, deserve separate research and may be separate bug reports

I corrected Version due to comment 14

May I remind you to <http://wiki.documentfoundation.org/BugReport>:
With the result I see here all your work keeps private innocent pastime. May be you found out what the problem is, but you did not make that info available for others. It's improbable that someone will find this bug and even fix it. 
The result of the QA process should be that afterwards anyone can find all necessary correct info within few seconds and that someone will take the bug and fix it. 
Who the heck is "oddycenter@yahoo.com"? I never heard that name. Why is he the assignee?
Comment 17 Rainer Bielefeld Retired 2013-04-03 07:32:58 UTC
I really would like to know whether that happens with arbitrary documents or only with that one

Did you already check that?
Comment 18 sasha.libreoffice 2013-04-03 12:09:37 UTC
Created attachment 77381 [details]
test case created from scratch

Created new document, added header with enough hight, added there 2 lines, added frame into document, pressed F4, dragged author into frame, changed frame's anchoring to page
Then opened document in text editor, found there this element:
<style:default-style style:family="paragraph">
and inside changed property fo:language to be fo:language="de" and saved
Then opened in Writer again and added into document date field and another author field
Comment 19 Rainer Bielefeld Retired 2013-04-04 05:08:27 UTC
I did some additional research, I'm afraid unfortunately without useful results.
I failed to create a new sample document (similar to Sasha's simplified one) from the scratch. But When I copied the date line from "bugSerialLetter-simplified.odt" to my document the problem appeared, what ever that might mean.

"bugSerialLetter-simplified.odt" seems to contain some invalid ODF ("Error: unexpected attribute "style:contextual-spacing""), but the problem persisted after I saved document with valid ODF.

Thank you for additional tests!
I tested your "test case created from scratch", but I did not see anything unexpected?! "asdf 03.04.13" was visible in print form letter preview for all pages with contents. What were your observations?

After copy / Paste of "Salzburg, 4. April 2013" from "bugSerialLetter-simplified.odt" to your latest sample the effect appeared, in all previews except first page "Salzburg, 4. April 2013" is missing.
Comment 20 Rainer Bielefeld Retired 2013-04-04 05:09:24 UTC
Please change  Status to ASSIGNED and add yourself to "Assigned To" if you accept this Bug or forward the Bug if it's not your turf
Comment 21 Joel Madero 2014-07-09 14:57:50 UTC
I am removing bibisectrequest from this. I don't see anything saying it's a regression from some version post 3.5, nor do I see really straight forward reproducible steps.
Comment 22 Alex Thurgood 2015-01-03 17:40:24 UTC Comment hidden (no-value)
Comment 23 Robinson Tryon (qubit) 2015-03-05 18:20:11 UTC
(In reply to sasha.libreoffice from comment #14)
 But it looks like in 3.4.2 this works correctly. But in
> 3.5.0 it works wrong. Looks like regression.

Too bad -- that's outside our bibisect range
Whiteboard -> notBibisectable
Comment 24 Robinson Tryon (qubit) 2015-12-10 01:26:19 UTC Comment hidden (obsolete)
Comment 25 Xisco Faulí 2016-09-14 22:14:47 UTC
Replacing keyword 'notBibisectable' by 'preBibisect' as this bug is outside the bibisect range
Comment 26 QA Administrators 2017-10-23 13:59:15 UTC Comment hidden (obsolete)
Comment 27 QA Administrators 2019-12-03 14:00:55 UTC Comment hidden (obsolete)
Comment 28 QA Administrators 2021-12-04 04:43:38 UTC Comment hidden (obsolete)
Comment 29 hc.stoellinger 2021-12-04 08:49:14 UTC
To start with - I am really sorry I didn't follow through with this "bug". Unfortunately I stopped working in this area when I retired from my function as the person responsible for IT-aspects in 2015. I know that the database and the files concerned do not exist anymore either. So, unfortunately I cannot really do anything to help closing the bug. However, seeing as I didn't report back to you anymore during all these years, I assume it was fixed in a newer version. 
H. Stoellinger