Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 3736 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

My cable company asked me to track programming to troubleshoot a problem. I have a single table file with just 29 fields and two very simple custom scripts. The "loopy" script that's a problem:

 

Go to Record/Request/Page [First]

Loop

Duplicate Record/Request

Insert Calculated Result [select TVSeries::Date Show; TVSeries::Date Show +7]

Go to Record/Request/Page [Next; Exit after last]

End Loop

Go to Record/Request/Page [First]

 

The purpose of this script is to create and maintain a unique list of shows for each week. The previous week's shows are duplicated and the newly created week's list of shows gets modified manually. The list is printed weekly for the cable company.

 
Problem:
out of 34 records on a list layout it duplicated 25 records without a problem
it skipped the 2nd, 11th, 16th, 19th, 20th, 21st, 23rd, 32nd and 33rd records
there's nothing different or special about the skipped records
 
I just can't see why it's not duplicating all 34 records. Can someone tell me what I'm missing here?
Posted

Skipped by date:

Sept 8 original: 6 skipped: 1

Sept 9 original: 3 skipped: 1

Sept 10 original: 8 skipped 4

Sept 11 original: 4 skipped: 1

Sept 12 original: 1 skipped: none

Sept 13 original: 2 skipped: none

Sept 14 original: 7 skipped: 2

Posted

I suggest processing the found set from the end: 

Go to Record [ last ]
Loop
  Exit Loop If [ not Get ( FoundCount ) ]
  Duplicate Record
  Set Field [ Shows::date ; Shows::date + 7 ]
  Omit Record
  Omit Record
End Loop
Show all Records
Go to Record [ first ]
  • Like 1

This topic is 3736 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.