Capture a value in Crystal Reports

Posted on 2014-11-18
Last Modified: 2014-12-01
I have a report that displays warranty item count totals based on month.  The totals change daily as new items are added (open) and existing items are completed (closed).  I would like to capture those values at the end of each month, so that I can see a trend.  Example:  
As of 11:59 PM, January 31st, 2014. the total open warranty items was 58.
As of 11:59 PM, February 28th, 2014. the total open warranty items was 52.
As of 11:59 PM, March 31st, 2014. the total open warranty items was 46.
As of 11:59 PM, April 30th, 2014. the total open warranty items was 38.

The formula must capture the count of open items and then save that number as a value that I can reference as a static number.  

Thanks in advance for any suggestions.
Question by:GStoner
  • 3
  • 2
  • 2
LVL 100

Expert Comment

ID: 40450814
I assume you mean in the report and not elsewhere as in another application or in a SQL query.

What are you trying to do with the numbers?

You could produce counts (as summary values) for each month then use them in the report footer to show trends.

What data do you have available that the counts are based on?


Author Comment

ID: 40450848
Yes, I would want to display the results in the report.

I simply want to display a point in time count.

The count would be based on a completion date.  If the item is open, the date value is 01/01/1900.  When the item is completed, an actual date is assigned.

Jan    Feb    Mar
58     52      46

I want to capture those numbers at a point in time.  I don't want the January and February count to change as items are completed.  The formula would have to count how many items have a date of 01/01/1900 as of 1/31 and then store that count as "January Total".  

Some of those item will then be completed over the next month, as well as new items added.  Again, the formula would count how many items have a date of 01/01/1900 as of 2/28 and then store that count as "February Total", and so on.
LVL 18

Expert Comment

ID: 40450922
You can run a report and calculate the totals in a cross tab in real time. I guess you have a Open and Closed date for each item . If yes , you can get the number of open items as of the end of each month. It is never a good idea to stash the data
What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.


Author Comment

ID: 40450978
Here's the problem if I count them in real time.  As time goes by, the real time numbers will change.  I want a static snapshot what was open at the end of each month, regardless of when the items were entered into the system.  If I use real time data, as any open items are closed, I think the prior month totals will change.  Again, I want a record and they should not change as time goes by.
LVL 100

Accepted Solution

mlmcc earned 500 total points
ID: 40451093
If you have the appropriate data you can do that in Crystal.

I assume you have the following
Warranty Item Id
Date Opened
Date Closed
Warranty Problem Description
Warranty Item Status

With that you could with the help of formulas capture what you want.

If you don't have the closed date but just an indication of its status then you won't be able to do it in Crystal.
Crystal does with the aid of outside tools have the ability to write outputs to a database.  You would have to have another report to use those outputs.  I have never done anything like that but there are tools that can help

Visual Cut from Millet Software could do it for you

 From the benefits
ODBC Exports can replace or append to existing tables. This provides ETL (Extract, Transform, Load) and scheduled data snapshot functionality.  

I expect there are other tools that can do it also.

I think it would probably be better to use an application to do the updates and capture that data into another table

LVL 18

Expert Comment

ID: 40451595
I was part of the team , which developed R-Tag, which is using a newer technology and provides unbeatable number of options to export data. Nevertheless, these kind of tools are not designed to manage data. They are designed to run reports. What will happen if you run the report twice and it exports the data 2 times ?
You need to  prepare your data in  a way , which will allow you to generate reports without saving a copy. A sample structure will involve 2 dates - CreatedDate when the record was physically created and EffectiveDate when the record become effective.   For example you may receive an email to close a record after hours on November 28th - Friday, but you will be able to close it on December 1st - Monday. The EffectiveDate will be November 28th and CreatedDate - December 1st,. Then, you can choose, which date to use in your report.

RecordID  CreatedDate   EffectiveDate       Status
ABC           1/1/2014          1/1/2014              Open
ABC           12/1/2014        11/28/2014         Close

This is a classic AsOn - AsIfOn structure and will allow you to report by the status at a specific point in time. For example you can easily find that ABC was effective 1/1/2014-12/28/2014 and at the same time you can report your data by the time it is created

Author Closing Comment

ID: 40473812
I reviewed and demoed Visual Cut and found, that while cumbersome, it will do what I need in order to capture and export point in time information.  I actively use another program, reportal (, which has similar schedule and export functionality, so my plan is to try using reportal first.  If that doesn't work, I will go back to Visual Cut.

Thanks for the recommendation.

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

Crystal Reports: 5 Tests for Top Performance It is complete, your masterpiece report.  Not only does it meet your customer’s expectations, it blows them out the water, all they want is beautifully summarised and displayed in a myriad of ways. …
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…
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…
Here's a very brief overview of the methods PRTG Network Monitor ( offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

708 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