Call us: 505-NEXTPRO (505-639-8776)

Reports · Tips

Custom Groups in ProLaw® Reports

October 12, 2024

Modify the Group By Fields

  1. Double click on the dataset for the group by fields.
  2. Change the Query type from Stored Procedure to Text.

Your query will begin with this:

SELECT ColumnName, ColumnLabel
FROM GroupOrderAssistantView
WHERE IsGroupBy = 'Y' AND SearchTableName = 'YOURTABLEHERE'
ORDER BY ColumnLabel

Replace YOURTABLEHERE with the name of the type of report you are running. You can find the value by running:

SELECT * FROM GroupOrderAssistantView

To add a custom field, use a UNION:

SELECT ColumnName, ColumnLabel
FROM GroupOrderAssistantView
WHERE IsGroupBy = 'Y' AND SearchTableName = 'Transactions'
UNION
SELECT 'Category', 'Matter Category'
ORDER BY ColumnLabel

Here, 'Category' is the database field name and 'Matter Category' is the label shown to the user.

Modify the Fields Dataset

Make sure your group-by field also exists in your main dataset. For a Transactions report, switch the dataset to "Text" mode and add the required field with a LEFT OUTER JOIN. Save and deploy the report — your new field will appear in the Group By dropdown.

Have a ProLaw® question?

Our team is here to help with anything ProLaw® — from quick questions to complex implementations.

Get in touch