# Use sum and working lines

{% hint style="info" %}
User permission: Budgets & Forecasts
{% endhint %}

Sometimes, your budget values are made up of details not shown in the Profit and Loss statement. You can use sum or working lines to include this detail in the Main tab. Then, you and your team can see the breakdown of where money is coming from or going to and get answers to your questions straight away.

{% hint style="success" %}
Sum and working lines are great for starting your budget and adding basic details and calculations. However, if you don’t want your Main budget tab to have such detail or if one working line drives multiple budget rows, use a [Manual Entry tab](/budgets-and-forecasts/owner-and-administrator/add-worksheet-tabs/manual-entry-tab.md) instead.
{% endhint %}

**Sum lines** automatically calculate budget values. The values in the sum lines *sum up* to the main (parent) row. Sum lines are handy for expense accounts, such as office supplies and maintenance, that typically have supporting schedules managed elsewhere (external spreadsheet). Rather than viewing only the total value in the budget and looking elsewhere for the details, you can use sum lines to view the breakdown of the total right underneath the main budget row. For example, you might have a row for the Maintenance expense with multiple sum lines underneath for the cost of painting, roof replacement, and so on.

**Working lines** are more versatile than sum lines, and you can use them in two ways: add the data for information purposes or reference the data in formulas in the main budget row. Working lines are particularly handy for managing budget items based on a percentage of another item. For example, you might budget 2% of sales for your Advertising expense. You can enter the percentage into the working line and use a formula to calculate the expense, referencing the percentage and the Sales value. Then, if the sales value increases, the Advertising expense increases automatically.

{% embed url="<https://phocassoftware.wistia.com/medias/u1900zyobg>" %}
Use sum and working lines
{% endembed %}

## Add a sum or working line to one row

Find the row for which you want to add the line. Hover over the first column of that row, click the blue **Add** button that displays, then select **Working line** or **Sum line**.

<div align="left"><figure><img src="/files/qJHyNQMnvmmgZpz1X8aE" alt="" width="310"><figcaption></figcaption></figure></div>

Then select either **Working line** or **Sum line** as required.

<div align="left"><figure><img src="/files/0qbP2CMf9mYsGQ00IJpQ" alt="" width="314"><figcaption></figcaption></figure></div>

<details>

<summary>Example: Use a sum line to build up your insurance costs</summary>

Suppose your Insurance budget item is made up of three types of insurance items that aren’t individually accounted for in the Profit and Loss but you want to budget for each type of insurance, as these costs are expected to be incurred.

Add a sum row for each type of insurance, then enter the values in the applicable cells. The values in the Insurance account row automatically update to reflect your additions. You can no longer edit the main budget row, as it is effectively “driven” off the new sum rows.

<div align="left"><figure><img src="/files/Xn67lMAY2xgHkfxhG08y" alt=""><figcaption></figcaption></figure></div>

</details>

<details>

<summary>Example (video): Add more detail with sum lines</summary>

{% embed url="<https://phocassoftware.wistia.com/medias/pys36vcvx3>" %}

</details>

<details>

<summary>Example: Use a working line to calculate your interest expense</summary>

Suppose your Interest Expense budget item is a function of the current loan balance and a variable interest rate.

Add three working rows, one each for the loan balance, repayments and interest rate. Next, use a formula in the first Interest Expense cell to calculate the loan balance across the 12-month period (= Interest Rate \* Loan Balance / 12), then [copy the formula forward](/budgets-and-forecasts/contributor/edit-values-in-a-worksheet/copy-and-paste-values.md).

<div align="left"><figure><img src="/files/Xg1HBhYDUcTr8qip1YPz" alt="" width="360"><figcaption></figcaption></figure></div>

As the loan balance will change each month (increasing by the interest change and reducing by any repayments), use a formula in the second Loan Balance cell to calculate the loan balance value (= Loan Balance + Repayments + Interest Expense), then copy all rows forward to populate the remaining cells.

<figure><img src="/files/hQJ9Hk9ExbadYDnmC8qz" alt=""><figcaption></figcaption></figure>

Now if you change the interest rate or repayments amount, the system will automatically update the Interest Expense values.

<div align="left"><figure><img src="/files/EMbbvJtiQ11EuWHKy4gC" alt=""><figcaption></figcaption></figure></div>

</details>

<details>

<summary>Example (video): Use working lines</summary>

{% embed url="<https://phocassoftware.wistia.com/medias/x4x5c5uzf2>" %}

</details>

{% hint style="success" %}
Watch the [Budgets & Forecasts 101 – expenses](https://www.phocassoftware.com/customer/training-series/budgets-forecasts#sessions) PUG Training session for more examples, including how to:

* Add two working lines and refer to them in a formula to calculate the value of the Digital Marketing expense.
* Add two working lines to multiple *like* rows in the budget simultaneously, then refer to the lines in a formula to calculate the value of the Digital Marketing expense. It also shows how to use the copy forward and copy down features to quickly populate the Digital Marketing expense rows, and change the measure format of the working lines to view decimal points.
* Add sum lines for three events under the Trade Show expense to automatically calculate the total expense value.
  {% endhint %}

## Add sum or working lines to multiple rows in bulk

1. Use the search box to quickly find the rows for which you want to add lines.
2. Select the applicable rows, then use either of these methods:
   * Click the **Row** menu, then select **Working line** or **Sum line**.
   * Hover over the first column of any selected rows, click the blue **Add** button that displays, then select **Working line** or **Sum line**.<br>

     <div align="left"><figure><img src="/files/KdbMoFtLUrPapwL7BmF2" alt="image-20240430-215219.png" width="466"><figcaption></figcaption></figure></div>
3. In the **Add \[sum or working] lines** window, enter a name for the sum line and click **Apply**. If you want to add a working line instead, click the toggle button to switch the sum line to a working line, then click **Apply**.<br>

   <div align="left"><figure><img src="/files/ETi8RjlNhkQAD8hyFRlV" alt="" width="469"><figcaption></figcaption></figure></div>

## Customize the format of the measures in a working line

Click the menu button (three dots) at the start of the working line and define your custom format. See [Format measures in working and sum lines](/budgets-and-forecasts/owner-and-administrator/customize-the-format-of-measures.md#format-measures-in-working-and-sum-rows) for more information.

<div align="left"><figure><img src="/files/jj2rUTzkS0tCLm8WCndW" alt="image-20240212-230741.png" width="276"><figcaption></figcaption></figure></div>

You don't have the option to apply a custom format to sum lines because it sums up to its parent row.

## Delete a sum or working line <a href="#usesumandworkinglines-deleteasumorworkingrow" id="usesumandworkinglines-deleteasumorworkingrow"></a>

Expand the sum/working line, then hover over the first column of that row to display the **Delete** button. Click the **Delete** button, then click **Delete** to confirm.

<div align="left"><figure><img src="/files/rkVToZzh0Nk4ZiJpT5o6" alt="" width="265"><figcaption></figcaption></figure></div>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.phocassoftware.com/budgets-and-forecasts/contributor/edit-values-in-a-worksheet/use-sum-and-working-lines.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
