Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: Using Max Parameter Value for Record Select Post Reply Post New Topic
Author Message
jade
Newbie
Newbie


Joined: 11 Feb 2007
Online Status: Offline
Posts: 1
Quote jade Replybullet Topic: Using Max Parameter Value for Record Select
    Posted: 11 Feb 2007 at 8:01pm

Hi,

 

I have employee sales records that are currently grouped by:  Region à District à Store à Employee Name.  The records are then sorted by sales date at the employee name level.   I also have a parameter that lets you select which time period you would like (?DateRange).  The problem I’m running into is that if an employee moves then they’ll appear under different store numbers. 

 

Is there any way to write a record select formula so that each employee’s sales records will be grouped based on the max value of the DateRange parameter?  For example:

 

In 200601, Jane was located in:

Region: New York

District: Buffalo

Store: 1234

 

But in 200603 she moved to:
Region: Pennsylvania

District:  Pittsburgh

Store: 2222

 

Is there anyway to have the records grouped/sorted so that all of Jane’s records fall under Pennsylvania, Pittsburgh, Store 2222 if the DateRange parameter values are 200601 – 200603?

 

Basically the store that falls under the max value of DateRange parameter will get credit for all earlier sales.

IP IP Logged
BrianBischof
Admin Group
Admin Group
Avatar

Joined: 09 Nov 2006
Online Status: Offline
Posts: 2458
Quote BrianBischof Replybullet Posted: 12 Feb 2007 at 12:04am
I did a similar post a couple days ago. What you need to do is use a Command object or a stored procedure to create a custom SQL statement to build the data you need. Check out the post here

http://www.crystalreportsbook.com/forum/forum_posts.asp?TID=202


Please support the forum! Tell others by linking to it on your blog or website:<a href="http://www.crystalreportsbook.com/forum/">Crystal Reports Forum</a>
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.031 seconds.