Link to home
Start Free TrialLog in
Avatar of edrz01
edrz01Flag for United States of America

asked on

Need assistance to modify a Crystal Report with an existing date field that Is Not Null and a date range for that field

We have a Crystal Report that needs to show a date field (p_termdate) that Is Not Null in a modified report. This report was modified from a full employee listing. However, since the request is to show only those employee’s with a termination date, we will also need to apply a start/end date for HR to enter based on the termination date for the report. I have never modified a Crystal Report and am asking for some assistance to modify this Employee Termination Report List.

This is the field to base the report on:
{HRPERSNL.p_termdate}
ASKER CERTIFIED SOLUTION
Avatar of Mike McCracken
Mike McCracken

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of edrz01

ASKER

I will check your solution tomorrow and evaluated the output. Thank you mlmcc...
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of edrz01

ASKER

I am using {?StartDate} to {?EndDate}
And I am receiving an Error "This field name is not known" with {?StartDate} to {?EndDate}
Avatar of edrz01

ASKER

Seems the Crystal Reports does not like:
{?StartDate}
{?EndDate}
{?DateRange}

I am receiving an Error "This field name is not known"
Avatar of edrz01

ASKER

Disregard for now: I did not add the Parameter ?StartDate, ?EndDate or ?DateRange... will try again in the morning.
Avatar of edrz01

ASKER

James I did use your recommendation  {HRPERSNL.p_termdate} in {?StartDate} to {?EndDate}

However, as a very new user to Crystal Reports, I was unfamiliar with the initial set to create new Parameters StartDate and EndDate. Eventually, I was able to figure what was missing... which leads to the length of time to respond adequately.

The next missing step was 'where' to place the statement above, which I now understand it should be in the Record Selection Formula Editor.

Now the Report asks for the Date Range to Preview. One additional piece I added:
{hrpersnl.p_active} = "T" and {HRPERSNL.p_termdate} in {?StartDate} to {?EndDate}
Where p_active checks to see if the employee is Active or Terminated 'T'.

Thank you for your advice and recommendation.
Avatar of James0628
James0628

mlmcc should probably get most of the points.  He said that you needed to add a parameter, and to use the Select Expert (Report > "Select Expert") to add the test.  I just added the part about testing for nulls (and it seems like you're not actually using that).

 You can use the "Request Attention" link under your first post to ask to have the question re-opened, and then split the points between us if you like.

 James
Avatar of edrz01

ASKER

Approved