I am using Oracle Report Builder:
I have a boolean field that I want to display a check mark(will settle for an asterisk) if the value is TRUE. If false, display nothing.
Is this possible using Conditional Print Expression or a Data Formula? What Formatting is required?
[Solved] Conditional Print Expression or Formula
-
nathan3553
- Posts: 17
- Joined: Sat Oct 18, 2014 6:35 pm
[Solved] Conditional Print Expression or Formula
Last edited by nathan3553 on Thu Oct 23, 2014 7:09 pm, edited 1 time in total.
OpenOffice 4 on Windows 7/OpenOffice 4 on MacOSX
Re: Conditional Print Expression or Formula
As far as I know, formatting options for Boolean fields only give TRUE and FALSE.
I do it in a Query for the report.
Replace Yes and No with whatever text you want.
Regards,
Nocton
I do it in a Query for the report.
Code: Select all
CASEWHEN( [BooleanField], 'Yes', 'No' )Regards,
Nocton
OpenOffice 4.1.16 on Windows 10 & 11
Re: Conditional Print Expression or Formula
The "normal" reports created without the report builder extension are simple Writer tables. When you open the report for editing (right-click>Edit) then you see a table with 2 place holder rows; first row for column labels, second row for data. Format the respective cell representing your boolean field in the second row.
This number format code shows the text "Yes" for any positive value (boolean TRUE is equivalent to +1), "" for negative numbers (does not apply) and "" for zero (boolean FALSE is equivalent to 0).
This number format code shows the text "Yes" for any positive value (boolean TRUE is equivalent to +1), "" for negative numbers (does not apply) and "" for zero (boolean FALSE is equivalent to 0).
Code: Select all
"Yes";"";""Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
-
nathan3553
- Posts: 17
- Joined: Sat Oct 18, 2014 6:35 pm
Re: Conditional Print Expression or Formula
It sounds like the answer is you cannot replace a boolean value of True with a check mark or asterisk, correct?
I'm currently already displaying True and when False, nothing.
I'm currently already displaying True and when False, nothing.
OpenOffice 4 on Windows 7/OpenOffice 4 on MacOSX
Re: Conditional Print Expression or Formula
Did you try any one of the 2 solutions?
Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
-
nathan3553
- Posts: 17
- Joined: Sat Oct 18, 2014 6:35 pm
[SOLVED] Re: Conditional Print Expression or Formula
I realized what was happening. I added the CASE WHEN logic to my query, but didn't remove the conditional print expression. Once removed and format type changed to text, the BooleanField displayed an asterisk as requested.
Thanks!
Thanks!
OpenOffice 4 on Windows 7/OpenOffice 4 on MacOSX