Symptom
How to check if Database Field is present in the list of Parameter
Environment
- Crystal Reports XIR2
- Crystal Reports 2008
Resolution
- Create the Formula in Crystal Report designer and drag it as per the logic to respective section of the report.
- To check if the Database Field is present in the list of Parameter created in the report we have to write the following code in formula :
numberVar position;
numberVar i:=0;
stringVar grpName;
booleanVar isGrpPresent:=false;
while(i<ubound(<parameter>))
do
(
i:=i+1;
position:=InStr(cstr(<parameter>[i]),"-");
grpName:=mid({<parameter>[i],position+1);
isGrpPresent:=(<database field>=grpName);
if isGrpPresent=true then exit while;
);
Keywords
Database Field , KBA , BI-RA-CR , Crystal Reports designer or Business View Manager , How To
SAP Knowledge Base Article - Public