Solved

Report Modifiction

Posted on 2013-06-28
7
161 Views
Last Modified: 2013-07-08
I need to make the following changes:

NORMAL section:

1. Change the group name "NORMAL" comes from the database . . but I would like that formatted to say "MOVEDIN"

So if NORMAL >> DISPLAY the text "MOVEDIN"

2. Ignore the MOVEDOUT text when group is NORMAL

Past section group:

1. Ignore the MOVEDIN date


Finally I would to be able to INSERT the count  of the moved in and moved on top the group section.

Can someone help me with these quick fixes?
Moveinout30day.rpt
0
Comment
Question by:Starquest321
  • 4
  • 2
7 Comments
 
LVL 34

Expert Comment

by:James0628
ID: 39286482
As I understand it, you want to:

 1) Change the displayed group name.
 Easy.  Create a formula that displays the desired values and put that in the group header.

 2) Do not display the text field that says "Moveout" (or the move out date) for the "Normal" records.
 Easy.  Right-click on each of those report fields and select "Format Text" (or "Format Field").  On the Common tab, click the formula (X+2) button to the right of Suppress and enter this formula:
{viewLeaseStats.StatusName} = "Normal"

 3) Do not display the text field that says "Movein", or the move in date, for the "Past" records.
 Same basic process as #2.  Add this suppression formula to the move in fields:
{viewLeaseStats.StatusName} = "Past"

 4) Show a record count in the group header.
 Easy.  The "problem" with your counts is that they're running totals, which are calculated as the records are read, so they won't be correct in the group header.  But you can just use a regular count summary.  Right-click on StatusName (or any field) and select Insert > Summary.  Select a Count summary, and make it for the group (not a grand total).  CR will insert the count in the group footer, but you can just drag&drop it in the group header.


 I'm attaching a copy of your report with all of those changes.  Your old group name and count fields are still there, but I added a groupname formula that displays the modified name (you can change that formula to say whatever you want), and a count in the group header.  And I added suppression formulas to the move in and out fields.  All of the fields that I added or changed are in green.

 James
Moveinout30day-J.rpt
0
 

Author Comment

by:Starquest321
ID: 39286922
James - perfect!

Now one more quick fix: For the moveout group it's important for us to know if the tenant stayed LESS THAN 6 MONTH.
Can you make it so you subtract the date Move IN - Move OUT ...if less than 6 MONTH PUT TEXT : ---> TENANT LESS THAN 6 MONTH!

Much much appreciated!
0
 
LVL 34

Expert Comment

by:James0628
ID: 39287194
How do you define 6 months?

 Literally 6 calendar months?  For example, 01/03 to 07/03 is 6 months, but 01/03 to 07/02 is not?

 180 days?

 180 days is simpler, so I'll start with that.  :-)

 Create a new formula (under "Formula Fields" in the "Field Explorer") like this:

if not IsNull ({viewLeaseStats.MoveOutDate}) and
 not IsNull ({viewLeaseStats.MoveInDate}) and
 {viewLeaseStats.MoveOutDate} - {viewLeaseStats.MoveInDate} < 180 then
  "TENANT LESS THAN 6 MONTH!"

 Subtracting one date from another gives you the difference in days.
 Change the message to say whatever you want.
 Put that formula in the detail section.

 It looked like some of the dates in your sample data were null, and those can cause problems in formulas like this, so I included IsNull tests to make sure that neither field is null before it does the subtraction.

 James
0
Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

 
LVL 100

Assisted Solution

by:mlmcc
mlmcc earned 100 total points
ID: 39288103
You can also use DateDiff and choose the timeframe.  For instance to get the months between 2 dates

DatDiff('m',{viewLeaseStats.MoveInDate},{viewLeaseStats.MoveOutDate} )

mlmcc
0
 
LVL 34

Accepted Solution

by:
James0628 earned 400 total points
ID: 39288532
The (potential) problem with using DateDiff to get the number of months is that it looks at _only_ the month and year, and ignores the days.  According to DateDiff, the difference between 06/30 and 07/01 is 1 month.  I'm guessing that that's not precise enough for this, which is why I didn't suggest it in my last post.  But I could be wrong.

 James
0
 

Author Comment

by:Starquest321
ID: 39306219
Issue solved! Thanks all
0
 
LVL 34

Expert Comment

by:James0628
ID: 39308312
You're welcome.  Glad I could help.

 James
0

Featured Post

Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

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. …
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…
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …
Along with being a a promotional video for my three-day Annielytics Dashboard Seminor, this Micro Tutorial is an intro to Google Analytics API data.

776 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