Naturally that works, too. What I didn't mention is that this particular task is getting both the first number for the day's batch and the last; the scroll cursor works nicely for that. We first do a "fetch first" followed by a "fetch last". In the case where the invoice number has rolled over during the day's batch this gives unambiguous results. Yes, that could still be accomplished by two SELECTs.

But the neat thing is that there are often many different ways to accomplish the same thing. What's your pleasure?

Emmitt,

Why not use a SELECT ... INTO .... WHERE COUNT = LAST

Dennis McGrath
Emmitt Dove
Manager, DairyPak Business Systems
Blue Ridge Paper Products, Inc.
40 Lindeman Drive
Trumbull, CT  06611
(203) 673-2231
[EMAIL PROTECTED]
[EMAIL PROTECTED]

Reply via email to