CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Apr 2010
    Location
    Portland, OR
    Posts
    1

    Question most recent activity with condition

    Hello code gurus,

    Does anyone know how to display the most recent visit date with a set condition in Crystal Report XI. Here's a sample table

    Client Visit Date Type
    A 01/01/10 Transfer
    A 01/30/10 Yes (most recent date for this client)
    B 02/02/10 Yes
    B 02/05/10 No
    B 02/20/10 Transfer (most recent date for this client)
    C 02/20/10 Transfer (most recent date for this client)

    I want to only display clients who has the type "Transfer" on the most recent visit date. The results should only include client B and C.

    I have tried Groups and sorting, but it I am not finding what I need.
    Please help. Thanks!

  2. #2
    Join Date
    Apr 2008
    Location
    Pittsburgh
    Posts
    103

    Re: most recent activity with condition

    Group the report Client.
    Create a running total.
    Field to summarize: the date field
    Type of Summary: Maximum
    Evaluate: Use a formula {type.field}="Transfer"
    On change of group.

    I believe that will give you the results you want.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured