[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index] [Date Index] [Thread Index]
[SQR-USERS Info] [SQRUG Home Page]

Re: To Break or not to Break



Perhaps down in the Company-Change and Dept-Change procedures you could add
an if statement that says:

if $Plans_Selected = 'ALL'

 { do the normal steps in this procedure}

else

{move 0 to #somedummyvariable,...just to complete the procedure without
doing anything}

end-if

This would in effect de-activate the break logic based on the user response
to the prompt.
John Douglas
Applications Support
Lockheed Martin Utility Services
740-897-2941
douglasjg@lmus.com





-----Original Message-----
From: Norm Schwartzman [mailto:norm_schwartzman@ISMBC.COM]
Sent: Friday, May 07, 1999 2:29 PM
To: Multiple recipients of list SQR-USERS
Subject: To Break or not to Break


I have a little dilemna and I hope someone can help me. The end user would
like an option to have a report not sort by department. I
know how to get around the order by part but I'm not sure what to do about
the on-break processing. I would like to make the on-break dynamic. Attached
is the code. Any help would be much appreciated. I am using SQR V3.013.3.

Thanks
Norm

! check if all Plans (ie: not sort by department)
  if $Plans_Selected = 'ALL'
     let $Order_By = 'ORDER BY A.COMPANY, C.DEPTID, B.Name, A.EMPLID,
A.PLAN_TYPE'
   else
    let $Order_By = 'ORDER BY A.COMPANY, B.Name, A.EMPLID, A.PLAN_TYPE'
   end-if

begin-SELECT
A.COMPANY      () on-break print=never level=1 procedure=Company-Change
C.DEPTID           () on-break print=never level=2 procedure=Dept-Change
A.EMPLID,
...
FROM PS_LEAVE_ACCRUAL A,
     PS_PERSONAL_DATA B,
     PS_JOB           C,
     PS_LEAVE_PLAN    D,
     PS_Employment    E,
     PS_Benef_Plan_Tbl F
WHERE ......
[$Order_By]
end-SELECT


Attachment: 060163.jpg
Description: JPEG image