Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: Values displaying issue Post Reply Post New Topic
Author Message
CrystalGirl
Newbie
Newbie


Joined: 22 Feb 2015
Online Status: Offline
Posts: 36
Quote CrystalGirl Replybullet Topic: Values displaying issue
    Posted: 29 Mar 2019 at 4:15pm
Hi,

I am having an issue running my Accounting Crystal Report, one of the fields is using a formula (called this formula as "Trans") as listed below:

IF isnull({Accounting.TransA}) THEN
   {Accounting.TransB} +' - '+{Accounting.TransC}
ELSE
    {Accounting.TransA} + ' - ' + {Accounting.TransD}

the issue is, when I run this accounting report, I am getting no data. So I did a trick or a test by going back to the above "Trans" formula and add (or edit) something like for example, add the comment sign (//comments) (see below)

//comments
IF isnull({Accounting.TransA}) THEN
   {Accounting.TransB} +' - '+{Accounting.TransC}
ELSE
    {Accounting.TransA} + ' - ' + {Accounting.TransD}


or adding space on top of the formula (see below)

space#1
space#2
IF isnull({Accounting.TransA}) THEN
   {Accounting.TransB} +' - '+{Accounting.TransC}
ELSE
    {Accounting.TransA} + ' - ' + {Accounting.TransD}

then click "Save and Closed" then I can see the value/data.

If I re run the report again, I will get the same issue (no data on report displayed), so I have to repeat the same trick I did like above and the report will show the data.

This happens every time when I run this report, so I have to keep repeating go back to the formula and do a trick like what I did in order the report to display the data.

Is this Crystal Reports version compatible or the service pack? I am using Crystal Reports SAP version 14.1.4.1327 service pack 4.

Anyone come across with this kind of issue before and how do you fix it?

Edited by CrystalGirl - 29 Mar 2019 at 4:38pm
IP IP Logged
kevlray
Admin Group
Admin Group
Avatar

Joined: 29 Oct 2009
Online Status: Offline
Posts: 1587
Quote kevlray Replybullet Posted: 01 Apr 2019 at 3:51am
I have not see this issue at all.  I know that checking for Nulls can be unpredictable (Set the formula editor to use Default Values for Nulls).  Also I trust using Len(string) = 0 instead of checking for a null.

IF len({Accounting.TransA})= 0 THEN
   {Accounting.TransB} +' - '+{Accounting.TransC}
ELSE
    {Accounting.TransA} + ' - ' + {Accounting.TransD}
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.016 seconds.