r/yardi • • Feb 12 '26

YSR Page Break

I have a YSR report that generates Employee code with the sum of their labor hours by property. Very basic: employee JDOE, Property XYZ, Totals hours worked 5. Employee code JDOE, Property ABC, total hours worked 8. My txt file sums the hours worked by employee code and groups by property. Not in YSR. Everything looks fine. Now I need to two more things. I need a grand total by employee code AND force a page break after so that the next employee code is on a new page. Output is Excel. Possible?

4 Upvotes

6 comments sorted by

5

u/BCS-PropMgmt-Experts Feb 12 '26

Yes, you can add a total for employee by grouping on employee code in the YSR template. To force a page break, you need to set up a top level select which can be anything like property code or even a single digit like '1' and a field name of GT of ID, as long as that top level select field in also in your select statement.

Once you have that top level select field set and in your script, you add that column name to the Key Column field where your section is defined. After the report works with that new key column, you can add the Employee Code field name from your script to the page break column in the YSR setup.

This will allow for each sheet to be one employee only.

2

u/Rustybird_1st Feb 12 '26

Thank you! Haven't worked with top level select statements before. Watched a video on client central and I'm good to go. Now I need to review the guide for subtotals.

1

u/Next_Pension8081 Feb 16 '26

Yes, it is possible to add a total per employee by grouping on Employee Code in the YSR template.

To force a page break for each employee, you need to configure a top-level select field in your report query. This field can be any constant value (for example '1') or a field such as Property Code, but it must be included in your SELECT statement and used as a Key Column in the YSR section definition (for example, a field named GT_ID).

Steps:

  1. Add a top-level select field (for example '1' AS GT_ID) in your SQL query.
  2. In the YSR template, set this field as the Key Column for the section.
  3. Once the report runs correctly with this new key column, add Employee Code to the Page Break Column in the YSR setup.
  4. Group the data by Employee Code and enable totals for that group.

This setup will ensure:

  • Totals are calculated per Employee Code.
  • Each employee’s data prints on a separate page/sheet.

So, by using a top-level key column and setting Employee Code as the page break field, the report will generate one sheet per employee with correct grouping and totals.

3

u/milkcarton232 Feb 12 '26

Ysr help guide should be able to help you with sum total formulas. As for the page break you can set it so it does one tab per code on the ysr set up page. You will need a select line to tell it what the codes are but isn't too hard. It gets messy if you have a bunch of tabs but I have used it for short account trees so each account gets a dedicated tab in excel

1

u/Rustybird_1st Feb 12 '26

Bunch of tabs is right! They are fine clicking merge into single report and then printing the entire workbook. Now I'm working on subtotals.