Solved

Formula to show blank field

Posted on 2011-02-17
5
675 Views
Last Modified: 2012-05-11
Hello,
I am trying to create this formula but it doesn't seem to work right.
I have Part No, Phase IN, Phase OUT and REV fields.
I want to show the most recent REV for that Part No. To id the most recent REV is if Phase OUT date is blank.

I tried this formula
if IsNull ({Phase_OUT}) then REV

but it is still grabbing the first REV or the first available line

is there a way to grab particular REV if Phase_OUT date is blank (didn't expire)

thank you,
0
Comment
Question by:Palmer_Admin
5 Comments
 
LVL 42

Expert Comment

by:zephyr_hex
ID: 34920208
are you placing this formula in the Details section of the report?

if so, how is your grouping done?

there are several different ways you can do this... but i think we need more information about the structure of your report.
0
 

Author Comment

by:Palmer_Admin
ID: 34920256
it is in my report header....

the grouping is done by Operation for that Part No

thanks
0
 

Author Comment

by:Palmer_Admin
ID: 34920281
I used Select Expert and set not equal to "", will that work?
0
 
LVL 100

Accepted Solution

by:
mlmcc earned 250 total points
ID: 34921168
You probably need  to use a SQL expression or perhaps a subreport.

Crystal works on 1 record at a time so if there are multiple records for a part then you would have to search for the one you want.

Is there a field the parts can be sorted on that would make the most recent rev the first or last record?
If so, group on part then sort on that  field and the one you want will be the first (group header) or last (group footer)

mlmcc
0
 
LVL 34

Assisted Solution

by:James0628
James0628 earned 250 total points
ID: 34924666
You said that you put your formula in the Report Header.  Is the report run for just one "Part No" at a time?  If it's run for multiple parts, putting that formula in the Report Header doesn't seem to make sense.

 Assuming that the report is run for one "Part No", you could try using a formula like the one that you posted, and then creating a second formula like the following and putting it in the Report Header:

Maximum ({your old formula})


 The theory is that any record where Phase_OUT is null has the REV value that you want, and your old formula outputs REV when Phase_OUT is null, and an empty string or 0 (depending on what type of field REV is) when Phase_OUT is not null, so the maximum value returned by your old formula should be the REV value from a record where Phase_OUT is null.

 Whether or not this will actually work depends on your data, report, etc.

 James
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

I hate sub reports and always consider them the last resort in any reporting solution.  The negative effect on performance and maintainability is just not worth the easy ride they give the report writer.  Nine times out of ten reporting requirements…
Hot fix for .Net Crystal Reports 10.2.3600.0 to fix problems with sub reports running on 64 bit operating systems ISSUE: Reports which contain subreports fail with error "Missing Parameter Value" DEPLOYMENT SERVER OS: Windows 2008 with 64 bi…
This video shows how to remove a single email address from the Outlook 2010 Auto Suggestion memory. NOTE: For Outlook 2016 and 2013 perform the exact same steps. Open a new email: Click the New email button in Outlook. Start typing the address: …
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now