Pathway: Database > Database Query
The Work Order entity contains the operational, service, and financial details for individual waste management jobs. It identifies the customer location, scheduled service, equipment, route, assigned driver and truck, and the status of the work order. It records whether the service was completed, along with completion details and the vehicle’s location at the time of service. The entity also tracks the financial performance of each work order, including revenue, service costs, disposal costs, surcharges, total costs, and profit.

This data can be used to monitor operations, including scheduled services, route performance, driver and truck assignments, completion status, and service exceptions. It can also support work-order analysis by comparing revenue, service costs, disposal costs, surcharges, and profit.
Initiating a Work Order Query
To generate a Work Order report using the Database Query tool, follow the steps outlined below. Reference the Database Query article for more details on how to use the tool for reporting.
- Go to the Database > Database Query screen.
- Click the New button in the top control bar. This will open the Select Main Entity popup.
- Select Work Order.
- After the Display Fields for the Users entity populate, select the check boxes for the fields you want to include in the report.
- If a specific order is required, select the fields in the order you want them to appear in the query.
- Click Run to execute the query. Results are generated in a new tab with the date and timestamp.
Columns Available for Display
The following data can be pulled in when running a Work Order report.
| Field Name | Description |
| Account and Site Information | |
| Account Id | Unique ID for the customer account associated with the work order. |
| Site Id | Unique ID for the customer service site. |
| Site Name | Primary name of the service site or customer location. |
| Site Name2 | Secondary or alternate name for the service site. |
| Site Service ID | ID for the specific service relationship or service configuration at the site. |
| Division Id | Unique ID for the operating division, branch, or facility responsible for the work order. |
| Service Region Name | Name of the geographic service region associated with the work order. |
| Service Region Id | Unique ID for the geographic service region. |
| Address Line 1 | Primary street address of the service location. |
| Address Line 2 | Additional address information for the service location, such as a suite, unit, building, or floor number. |
| City | City in which the service location is located. |
| State | State or province of the service location. |
| Zip | Postal or ZIP code of the service location. |
| Contact and Access Information | |
| Contact Id | Unique ID for the customer contact associated with the work order. |
| Contact Name | Name of the customer or site contact. |
| Contact Phone1 | Primary telephone number for the customer or site contact. |
| Contact Email | Email address for the customer or site contact. |
| Access Information | Instructions or restrictions for accessing the service location, such as closing times, gate details, or site-specific pickup requirements. |
| Requested By | Name or identifier of the person who requested the work order. |
| Work Order Identification and Classification | |
| Work Order Number | Business-facing number assigned to the work order. |
| Order Type | Category of work requested, such as scheduled service, on-call service, delivery, relocation, or dump/return activity. |
| Work Type Id | ID for the type of work performed. |
| Work Type Name | Description of the work performed, such as roll-off dump/return, front-load delivery, or front-load service. |
| Service Code Id | ID for the billable service code. |
| Service Code Name | Name of the billable service, such as a trash service, recycle service, delivery, relocation, or dump/return service. |
| Line of Business Id | ID for the line of business associated with the work order, such as roll-off or front-end loader service. |
| Service Record ID | ID for the related service record. |
| Service Record External Id | External-system identifier for the related service record. |
| Service Root Id | ID for the root or originating service record in a related service hierarchy. |
| Parent Service Record Id | ID for the parent service record associated with the work order. |
| Parent Service Record Work Order Number | Work order number of the parent service record. |
| Work Order PO Number | Purchase order number associated with the work order. |
| Created By User | User who created the work order. |
| Created Timestamp | Date and time when the work order was created. |
| Equipment, Driver, and Route Information | |
| Equipment Type Id | ID for the equipment type used or serviced. |
| Equipment Type Name | Name of the equipment type, such as a 40-yard roll-off container or an 8-yard front-load container. |
| Equipment Volume | Capacity of the container or equipment, generally expressed in cubic yards. |
| Driver Id | ID for the driver assigned to or completing the work order. |
| Driver Name | Name of the driver assigned to or completing the work order. |
| Truck Id | ID for the truck used to perform the work. |
| Truck Name | Name or fleet identifier for the truck used to perform the work. |
| Route Id | ID for the route associated with the work order. |
| Route Name | Name of the route on which the work order was scheduled or completed. |
| Route External Id | Route ID originating from an external routing or dispatch system. |
| Sequence | Position of the work order in the route sequence. |
| Route Default Disposal Location Id | ID for the default disposal location assigned to the route. |
| Route Default Disposal Location Name | Name of the default disposal location assigned to the route. |
| Scheduling and Time Tracking | |
| Scheduled Date | Date on which the work order was scheduled to be performed. |
| Original Scheduled Date | Initial scheduled service date before any rescheduling or date changes. |
| Calculated Start Timestamp | System-calculated date and time when the work was expected to begin. |
| Calculated End Timestamp | System-calculated date and time when the work was expected to end. |
| Start Timestamp Override | Manually entered replacement for the calculated start time. |
| End Timestamp Override | Manually entered replacement for the calculated end time. |
| Geofence Start Time Stamp | Date and time when the vehicle entered the service-location geofence. |
| Geofence End Time Stamp | Date and time when the vehicle exited the service-location geofence. |
| Completion Datetime | Date and time when the service activity was completed. |
| Completion Date | Calendar date on which the work order was completed. |
| Minutes | Duration of the work order or service activity in minutes. |
| Work Period | Accounting or operational period in which the work was performed. |
| Billed Period | Billing period to which the work order was assigned. |
| Material and Disposal Details | |
| Material Type Id | ID for the material collected or handled. |
| Material Type Name | Name of the material collected or handled, such as municipal solid waste or recyclable material. |
| Quantity | Billable or operational quantity associated with the service. |
| Work Order Weight | Weight of the material collected, transported, or disposed of for the work order. |
| Disposal Facility Name | Name of the landfill, materials recovery facility, transfer station, or other disposal facility used. |
| Destination Origin Facility | Origin or destination facility associated with the disposal movement. |
| Disposal Material Type Id | ID for the material type recorded at disposal. |
| Disposal Material Type Name | Name of the material type recorded at the disposal facility. |
| Disposal Quantity | Quantity of material recorded as disposed. |
| Disposal Cost | Disposal cost associated with the work order or load. |
| Disposal Costs | Total or allocated disposal costs recorded for the work order. |
| Status, Exceptions, and Completion | |
| Status Code | Numeric or system code representing the current work order status. |
| Status Text | Readable description of the work order status, such as scheduled or service completed. |
| Status In Progress Timestamp | Date and time when the work order entered an in-progress status. |
| Exception Reason Code | Code identifying an exception or deviation from the planned service. |
| Exception Reason Name | Description of the exception or reason the planned work was changed or affected. |
| On Call Reason Code | Code identifying why the work order was created as an on-call request. |
| On Call Reason Name | Description of the reason for the on-call service request. |
| Completed By User | User who recorded or confirmed completion of the work order. |
| Completion Note | Notes describing the completed service, site conditions, exceptions, customer instructions, or other completion details. |
| Completion Latitude | Latitude recorded at the time or location of service completion. |
| Completion Longitude | Longitude recorded at the time or location of service completion. |
| Note | General internal note associated with the work order. |
| Order Note | Instructions or comments provided with the original service order. |
| Service Note | Notes specific to the service being performed. |
| Optimization and Dispatch | |
| Optimization | Indicator or value showing whether the work order was included in route or dispatch optimization. |
| Optimization Distance | Distance associated with the optimized route or dispatch plan. |
| Optimization Expected Start Time | Expected service start time produced by route optimization. |
| Optimization Expected Service time | Expected duration or service time produced by route optimization. |
| Optimization Travel Time | Expected travel time associated with the optimized route. |
| Billing and Financial Information | |
| Invoice Date | Date associated with the invoice generated for the work order. |
| Posted Date | Date on which the work order was posted to billing or accounting. |
| Posted Status Name | Readable description of the posting or billing status. |
| Posting Status Code | System code representing the posting or billing status. |
| Posted User Id | ID for the user who posted the work order. |
| Posted User Name | Name of the user who posted the work order. |
| Revenue | Revenue amount associated with the work order before applicable surcharges or additional revenue components. |
| Work Order Revenue | Total revenue assigned to the work order. |
| Surcharge Revenue | Revenue generated from surcharges applied to the work order. |
| Total Revenue | Total revenue for the work order, including applicable service charges and surcharges. |
| Minimum Charge Amount | Minimum amount charged when the calculated service charge is below the applicable minimum. |
| Service Cost | Direct service cost associated with completing the work order. |
| Total Cost | Total cost associated with the work order, including service and disposal costs. |
| Profit | Profit amount calculated from total revenue less applicable costs. |
| Profit Percent | Profit expressed as a percentage of the applicable revenue. |
Entity Join Options
When running reports against the Work Order entity, the option to pull in data from other entities is provided by utilizing the Join feature in the Database Query tool.

Only select entities can join with other select entities. The option provided for Work Order is:
Reference the Database Query article for more details on how to use the Join option for more complex, detailed reporting.