crystal report formula

Posted by Sudhir under Sql Server on 2/3/2012 | Points: 10 | Views : 1560 | Status : [Member] | Replies : 1
i have set the formula in crystal report like

if({?eng_code}=" " then
{table.fdate}>={?fdate} and {table.tdate}<={?tdate} and {table.eng_type}={?eng_type}
else
{table.fdate}>={?fdate} and {table.tdate}<={?tdate} and {table.eng_code}={?eng_code}

comming variable eng_code is blank that mean first formula is working
but i have sql connection error
if i remove and {table.eng_type}={?eng_type} from the condition then crystal report working.

pls help me what's problem in this code

Sudhir




Responses

Posted by: Naraayanan on: 2/4/2012 [Member] Starter | Points: 25

Up
0
Down
Hi,
It is my guess,
Please change your code like this
   f({?eng_code}="null" then

{table.fdate}>={?fdate} and {table.tdate}<={?tdate} and {table.eng_type}={?eng_type}
else
{table.fdate}>={?fdate} and {table.tdate}<={?tdate} and {table.eng_code}={?eng_code}

and Refresh your report

Or
Please refresh your report/Create a new Crystal report.


Regards,
Lakshmi Naraayanan.S
http://dotnettechrocks.blogspot.in/
http://abaprocker.blogspot.com/

Sudhir, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response