Issue 73831 - "NextRecord" breaks conditional formating
Summary: "NextRecord" breaks conditional formating
Alias: None
Product: Writer
Classification: Application
Component: formatting (show other issues)
Version: OOo 2.1
Hardware: All All
: P3 Trivial (vote)
Target Milestone: ---
Assignee: AOO issues mailing list
QA Contact:
Keywords: needmoreinfo
Depends on:
Reported: 2007-01-24 18:03 UTC by rkollien
Modified: 2017-05-20 11:19 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---

Testdrive with all needed files. (24.61 KB, application/x-compressed)
2007-01-25 15:51 UTC, rkollien
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description rkollien 2007-01-24 18:03:31 UTC
querying the bugs database i found some bugs regarding the problem, that using
the "NextRecord" field command (Feldbefehl in german) breaks the evaluation of
conditional formating. As i found, all issues are marked as "fixed", but in my
constellation, the problem still exists. 

I have a database (tried ODBC, csv, Calc-table; no difference) with some records
containing accounting info. I created a writer document with a table with enough
rows to hold the maximum possible records for one bill. Each table row
(=database record) should be preceded by a little text. When the records are
less than the number of rows, the row of course shouldn't contain this text. So
i defined a conditional text like database.table.field NEQ "" "Preceding Text "
ELSE "". This is ok until the _last_ record is retrieved. In all subsequent rows
following the _last retrieved_ record, they evaluate like the last one did. IMO,
when the "end-of-file" is reached, evaluating the conditionals are stopped.
Reproducing this issue is very simple and works for all versions of OOo:

1) Create a CSV file containing some fields (lets assume "Name" and "Street")
and enter two (2) records:

"Bugsbunny";"Top of the hill"
"Donald Duck";"Somewhere"

2) Make a data connection to access the csv file in Writer
3) Create an empty Writer document, insert a table with five(!!) rows and three
4) Drag'n'drop "Name" to the first col on each row, "Street" to the third. 
5) In column two insert a conditional text like db.table.Street EQ "Somewhere"
"this shouldn't happen" ELSE "".
6) After the database field "Street" in each of the five rows insert the
"NextRecord" field (not in the last row, but that doesn't matter).
7) Print and you will see. Row three to five have "this shouldn't happen" in
column two as the last printed record evaluated to this.
Comment 1 michael.ruess 2007-01-25 08:47:08 UTC
Reassigned to ES.
Comment 2 eric.savary 2007-01-25 13:37:13 UTC
Please attach a sample document and database.
Comment 3 rkollien 2007-01-25 15:51:52 UTC
Created attachment 42462 [details]
Testdrive with all needed files.
Comment 4 rkollien 2007-01-25 16:04:23 UTC
The zip-file contains all needed files to reproduce the bug.
- report.csv contains the data
- report.odb is the database description. I think, you have to adjust the path.
The "database" is the flat csv-file "report.csv", UNICODE, Fieldseparator ";",
Textseparatort '"', first line contains column names.
- report.odt is the document containing the reporting table. The databasefields
are addressed as ""
- is the printed output of the report.odt as - of course - postscript.
Comment 5 eric.savary 2007-02-22 10:14:24 UTC
As described.
I can't find out why this fails.
Comment 6 rkollien 2009-05-12 14:17:34 UTC
This bug still exists in OOo 3.1.0. No tried to use the nativ postgresql
database with the JDBC driver on MacOSX. The conditional formating still doesn't
work. After printing the last record, all following table rows should be empty -
the conditional formating of the paragraph is defined to hide if the (a)
database field is not set (=empty). Tried "NOT" and "!"
as " == """ and " EQ """ and so on. Nothing triggers the
"hide paragraph" condition when the last record is retrieved.
Comment 7 Marcus 2017-05-20 11:19:47 UTC
Reset assigne to the default "".