[Stackoverflow] [Progress OpenEdge ABL] How to increase the process performance by reducing following codes?

Status
Not open for further replies.
T

Thiru malai

Guest
I have written a program using progress 4GL. The syntax is correct but don't know how to reduce the codes..We are the company working for seats and using progress 4gl..we have one table called shift maintenance which has shift time for every hours.Let explain with an example.

DEFINE VARIABLE FistshiftStartHour AS INTEGER NO-UNDO.
DEFINE VARIABLE FistShiftEnddHour AS INTEGER NO-UNDO.
DEFINE VARIABLE SecshiftStartHour AS INTEGER NO-UNDO.
DEFINE VARIABLE SecShiftEnddHour AS INTEGER NO-UNDO.

FIND FIRST shift WHERE shift.shiftsequence = 1 NO-LOCK NO-ERROR.
ASSIGN
FistshiftStartHour = shift.starthour
FistShiftEnddHour = shift.endhour.

FIND FIRST shift WHERE shift.shiftsequence = 2 NO-LOCK NO-ERROR.
ASSIGN
SecshiftStartHour = shift.starthour
SecShiftEnddHour = shift.endhour.


Like this i need to write a query for every shift hours and assign to two variables for 21 shift sequence.Is there any chance for reducing so much queries?(Note-I must to assign start and end time to individual variables).

Continue reading...
 
Status
Not open for further replies.
Top