Focal Point
[SOLVED] Millions of Dollars in InfoAssist?

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/5527089096

December 14, 2018, 02:08 PM
Doug
[SOLVED] Millions of Dollars in InfoAssist?
Is there an easy, out of the box, conversion to convert big decimals to Millions of Dollars in InfoAssist ('12,345,678.99' to '$12.345M'?

This image is from tableau. So I'm thinking: If tableau has it as an automatic conversion, then WebFOCUS should have something simple, if not automagic, to do this. Yeah, I know it's easy for chart creation. But, We need this for report creation in IA.


I know we can do the following. But, that's too complex for the average business users who is new to WebFOCUS. Smiler
MyBigNumber/A12='$' || (EDIT(EDIT(ThisBigNumber),'$$$$$$$99.999')) || 'M';
Or several other methods.

Thanks in Advance, Doug

This message has been edited. Last edited by: Doug,




   In FOCUS Since 1983 ~ from FOCUS to WebFOCUS.
   Current: WebFOCUS Administrator at FIS Worldpay | 8204, 8206
December 14, 2018, 08:17 PM
BabakNYC
I doubt this is an available mask. When I’ve had to do this, I just divided by 1,000,000 and put the word Millions in the column title.


WebFOCUS 8206, Unix, Windows
December 17, 2018, 07:59 AM
MattC
What about a COMPUTE D12.2Mm? This will change it as you can type in the "Mm".


WebFOCUS 8.1.05
December 17, 2018, 08:43 AM
BabakNYC
MattC: Thanks so much! I just learned something totally new here. I never knew about this mask. And if you just type D12.2m inside the format box in InfoAssist, you get the number in millions. Outstanding!


WebFOCUS 8206, Unix, Windows
December 18, 2018, 10:21 AM
Doug
👍 Yeppers, D12.2Mm does the trick in either a COMPUTE or DEFINE...

This message has been edited. Last edited by: Doug,
December 18, 2018, 11:01 AM
BabakNYC
As an FYI, D12.2Mk will give you the value in 1,000's (e.g. $45K). You can also use b for Billions and t for Trillions if you need those numbers.


WebFOCUS 8206, Unix, Windows
December 18, 2018, 03:08 PM
David Briars
DEFINE FILE CAR
 MYDCOST/D12.2Mm = DCOST;
END
TABLE FILE CAR
 PRINT DCOST
       MYDCOST
END  

Gives a 'FOC253 Invalid format spec D12.2Mm'.

I don't see formats like 'm', 't', or 'b', in the 81 'Describing Data with the WebFOCUS Language' manual.

Are you folks describing new formats available in 82 WebFOCUS?




Pilot: WebFOCUS 8.2.06 Test: WebFOCUS 8.1.05M Prod: WebFOCUS 8.1.05M Server: Windows Server 2016/Tomcat Standalone Workstation: Windows 10/IE11+Edge Database: Oracle 12c, Netezza, & MS SQL Server 2019 Output: AHTML/XLSX/HTML/PDF/JSCHART Tools: WFDS, Repository Content, BI Portal Designer & ReportCaster
December 18, 2018, 03:17 PM
BabakNYC
I believe these features were added in 8204.


WebFOCUS 8206, Unix, Windows
January 07, 2019, 04:33 PM
Doug
quote:
I believe these features were added in 8204.
Yes, it works in 8204 (in DEFINEs). But, not available in the 'Format Selection' section of IA's UI. D12CMm works.

How would this be accomplished in IA 8204? Is it available in a newer version: IA 8####?

This message has been edited. Last edited by: Doug,