oracle-apexoracle-apex-18.2

How to display trailing whitespace in Interactive Report


I'm using an Oracle APEX 18.2 interactive report to display some data of type NVARCHAR2 in an APEX column of type "Plain Text." Some data includes trailing spaces. When I view the interactive report, the trailing spaces are not shown. How can I prevent APEX from trimming the whitespace from NVARCHAR2 or VARCHAR2 data?

I've looked for a setting in the column attributes, but could not find anything that would change this behavior.


Solution

  • You won't find this supported in the apex attributes natively, but you can control the formatting by using custom css. Tobias Arnold describes a similar problem in this blog: https://www.apex-at-work.com/2018/03/interactive-report-standard-column.html

    .a-IRR-table tr td[headers*="description"]
    {
        white-space: pre;
    }