Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I test for increments of 1

Status
Not open for further replies.

geedubcpa

Programmer
Oct 5, 2005
19
0
0
US
I have a report that list all the tickets in numerical order for a month. How can i test to see if each number is one more than the previous number on the report.

Row 1 = 2500
if row 2 = 2501 ok
if row 2 = 2503 then i have a problem

Thanks for any ideas.
 
Hi,
If sorted in order then you could probably use the Previous function to test - Build a formula ( maybe call it ErrorFlag:
Code:
@ErrorFlag
If Previous({table.record.value}) <> ({table_record.value)- 1)
  Then
"We Have a Problem"
else
""

Place it after the field displaying the #..

( you should test as well for the first record, since it will never be = to (current -1))





[profile]

To Paraphrase:"The Help you get is proportional to the Help you give.."
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top