Skip to main content
Announcements
Defect acknowledgement with Nprinting Engine May 2022 SR2, please READ HERE
cancel
Showing results for 
Search instead for 
Did you mean: 
kdmarkee
Specialist
Specialist

NPrinting 17 - formatting percentage in pixel perfect

I can't seem to figure this out nor find help on this in the Community, and it seems like it should be easy.  I want to be able to show a percentage in my pixel perfect report without the "%" symbol.  For example, as 10.24.   I can pick the Percentage choice in the FormatString Editor of my field but this automatically add the "%" symbol.  I've tried a few variations as well as using a few formulas in the NP designer and assigning it as the Data Member but nothing is working.  Any help would be greatly appreciated.  Thanks.

1 Solution

Accepted Solutions
Ruggero_Piccoli
Support
Support

Hi,

Do a right click over the object with the original percentage field and add a new calculated field.

Add Calculated Field.png

Customize the expression to obtain your goal. For example I multiplied *100 and rounded to the second decimal. In the formula editor there are a lot of built-in functions to customize the calculation.

Then drag and drop the new field in the template.

Best Regards,

Ruggero

---------------------------------------------

When applicable please mark the appropriate replies as CORRECT https://community.qlik.com/docs/DOC-14806. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads as HELPFUL if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads as HELPFUL if you feel additional info is useful to others.



Best Regards,
Ruggero
---------------------------------------------
When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads with a LIKE if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads with LIKEs if you feel additional info is useful to others.

View solution in original post

8 Replies
Ruggero_Piccoli
Support
Support

Hi,

Do a right click over the object with the original percentage field and add a new calculated field.

Add Calculated Field.png

Customize the expression to obtain your goal. For example I multiplied *100 and rounded to the second decimal. In the formula editor there are a lot of built-in functions to customize the calculation.

Then drag and drop the new field in the template.

Best Regards,

Ruggero

---------------------------------------------

When applicable please mark the appropriate replies as CORRECT https://community.qlik.com/docs/DOC-14806. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads as HELPFUL if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads as HELPFUL if you feel additional info is useful to others.



Best Regards,
Ruggero
---------------------------------------------
When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads with a LIKE if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads with LIKEs if you feel additional info is useful to others.
kdmarkee
Specialist
Specialist
Author

Thank you, that is a feature I haven't used yet and I guess forgot was there.  Is there anyway to format it so that it always shows 2 decimal places?  For example, I want 3.3 to appear as 3.30 and 0 to appear as 0.00.  I tried a few of the available functions but no luck.  Thanks.

Ruggero_Piccoli
Support
Support

Hi,

Apply the format string #.00.

Remember to mark the correct answer.

Best Regards,

Ruggero

---------------------------------------------

When applicable please mark the appropriate replies as CORRECT https://community.qlik.com/docs/DOC-14806. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads as HELPFUL if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads as HELPFUL if you feel additional info is useful to others.



Best Regards,
Ruggero
---------------------------------------------
When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads with a LIKE if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads with LIKEs if you feel additional info is useful to others.
kdmarkee
Specialist
Specialist
Author

I did a silly thing, sorry for wasting your time.  I had tried applying that formatting but I failed to correct my Calculated Field after I was trying some other things and falsely thought the formatting wasn't working, but it really does (once I had corrected my Calculated Field, of course).  Thanks again.

Ruggero_Piccoli
Support
Support

Hi,

Don't worry. Public conversations will be useful for other people with the same issue in the future.

Best Regards,

Ruggero

---------------------------------------------

When applicable please mark the appropriate replies as CORRECT https://community.qlik.com/docs/DOC-14806. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads as HELPFUL if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads as HELPFUL if you feel additional info is useful to others.



Best Regards,
Ruggero
---------------------------------------------
When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads with a LIKE if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads with LIKEs if you feel additional info is useful to others.
kdmarkee
Specialist
Specialist
Author

So this worked in a proof of concept I did but now that I am incorporating it into my actual report, my column is blank and I can't understand why when am I doing the same thing.  What can cause a column appear blank?

Here are my screenshots of the set up and outcome...the calc fields, the first calc field chosen as the data member of my column item, the format is {0:0.00}.  Thanks.

calc field.PNG

chosen calc field.PNG

calc field outcome.PNG

kdmarkee
Specialist
Specialist
Author

Turns out I have to include the original field on the template (and hide it since I don't want to display that one) in order for my calculated version of that field to display properly.  Is this a bug or is there some other property that needs to be set somewhere.  This seems like a poor design if this is how it has to work.  I have a report of 18 columns and 9 of those will be replaced by their own calculated field, but I now have to figure out how to squeeze the 9 additional original fields (although hidden from the output) on the template too? 

Ruggero_Piccoli
Support
Support

Hi,

Please open a different community conversation for a different question. This will helps other people with the same question to find an answer. Thanks.

The source object with the fields you want to use in your calculation bust be added to the template but it is not mandatory to add all its fields inside the template and they can be hide in the source document. We suggest to create QlikView documents and/or Qlik Sense apps specific for the reporting usage. It is not mandatory but it helps when you need to add updates needed for reporting but you don't want to show them to users. It helps also to optimize performances.

Best Regards,

Ruggero

---------------------------------------------

When applicable please mark the appropriate replies as CORRECT https://community.qlik.com/docs/DOC-14806. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads as HELPFUL if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads as HELPFUL if you feel additional info is useful to others.



Best Regards,
Ruggero
---------------------------------------------
When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads with a LIKE if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads with LIKEs if you feel additional info is useful to others.