| Author |
Message |
dax007
Newbie
Joined: 17 May 2018
Online Status: Offline
Posts: 25
|

Topic: How to use Sum which has value hyphen "-" Posted: 14 Jun 2018 at 6:12am |
|
Hello,
I'm using following to display play hyphen "-" if the value is NULL
If isnull {Command} then
' -'
else
ToText ({command} ,1)
This works just fine,but I want to sum of that group and if the group has only one row which is null then that that value display blank instead I want it that as hyphen "-"
For example:
AAA
A111 -
Total AAA
BBB
B111 -
B112 10
Total BBB 10
As you can see from above example "Total AAA" show just blank instead I want it to display - (Hyphen)
Any suggestion?
Thank you
|
IP Logged |
|
DBlank
Moderator
Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
|

Posted: 14 Jun 2018 at 7:42am |
|
is there a difference, for your data purposes, between 0 and null? or a SUM=0 vs. all NULL values for the group?
|
IP Logged |
|
dax007
Newbie
Joined: 17 May 2018
Online Status: Offline
Posts: 25
|

Posted: 14 Jun 2018 at 8:13am |
|
Thanks for your reply. That's the requirement, users wanted to display "-" instead of "0" if it is NULL.
But when I add up the values creates issue when it's "-"
Thanks again..
Also I tried some thing like
Leave the datatype for the column value to Number. Then setup a new formula to display hyphen if the value is null. Then for total use the following formula
If ISNULL ({RTotal0})
Then
' -'
Else
TOTEXT ({RTotal0},1)
When I validate it does not give me any error but when It "Save and Close" it gives me following message.
"A Number, Currentcy ammount, data, time, or date-time is required here."
Any help? Thanks..
Edited by dax007 - 14 Jun 2018 at 10:49am
|
IP Logged |
|