Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: non sequenced entry Post Reply Post New Topic
Author Message
unclejohnny
Newbie
Newbie


Joined: 02 Jul 2008
Location: United States
Online Status: Offline
Posts: 3
Quote unclejohnny Replybullet Topic: non sequenced entry
     Posted: 03 Jul 2008 at 12:52pm
I work for a company that has me produce a report based on the account numbers issued by clerks in a given day for a given year.  These results are typically in sequential order since they pull them off of a roll.  Sometimes, i.e. their roll runs out and needs replacement, they account numbers on the report will jump sequence.  My "higher-ups"  want me to note that gap with an "*" and continue on with the new sequence.  See example below.
 
525
526
527
528
529
530
531
*
601
602
603
604
etc.
 
I'm using Crystal Reports 2008.  I have the account numbers for each clerk listed in the details section.  I have them grouped by clerk number and then by account number to put them in order.  Any help would be appreciated.  Please let me know if I need to give more details.
 
John
IP IP Logged
venkatesha
Newbie
Newbie


Joined: 29 Jun 2008
Online Status: Offline
Posts: 35
Quote venkatesha Replybullet Posted: 03 Jul 2008 at 10:57pm
Create one more detail section  next to Account Number.

Place a Text box in that section below the Account Number with *. Then use the below formula for suppressing the newly added section. Section Expert -> Suppress

if((not OnLastRecord) and ({Sno.Clerk} = next({Sno.Clerk}))) then
{Sno.RollNo}+1= (Next({Sno.RollNo}))
else
    true;

If required make some changes accordingly. The logic is

I made an assumption its sequential so validating the next record whether current record record +1 if so suppress the section   
       {Sno.RollNo}+1= (Next({Sno.RollNo})) else display the same.

One more validation is its should not be last record, and numbers belong to same group else suppress the same
   


Edited by venkatesha - 03 Jul 2008 at 11:00pm
IP IP Logged
unclejohnny
Newbie
Newbie


Joined: 02 Jul 2008
Location: United States
Online Status: Offline
Posts: 3
Quote unclejohnny Replybullet Posted: 07 Jul 2008 at 12:03pm
Thanks so much for your help your help, venkatesha.  I should have added some more details about my needs.  I tried to use the second details section that you spoke of, but I ran into difficulties because they had me format the report so that the details were displayed as "format with multiple columns" in the section expert.  I managed to get a working solution by adding the following code to the formula that populates the details section.
 
if tonumber({vwdecalusage.decal})<> tonumber(next({vwdecalusage.decal}))-1
and
{vwdecalusage.teller}=next({vwdecalusage.teller})
and
{vwdecalusage.renew_mnth}=next({vwdecalusage.renew_mnth})
then   {vwdecalusage.decal} +"   *"
else {vwdecalusage.decal}
 
With this solution I'm appending an asterisk to the end of the number that preceeds the sequence gap.  The purpose of the asterisk is merely to alert the auditors to a break in the numbers.  They told me that that format was satisfactory.
 
 
IP IP Logged
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