When should I use uBAQ Method directive over BPM Method directive


There are many ways to achieve the same result in Epicor.

I did a lot of dashboards and I do not know when is a good time to use uBAQ Method directive over BPM Method directive. I find that I prefer to use uBAQ Method directive as the data in the BAQ contains all the fields that I need to do additional processing such as receiving job into inventory, creating purchasing Order.

It would depend on what user experience you are wanting to achieve. The many tools are for the many ways we can help the user with their job.

From your experience, is one of them perform faster than the others? For example, according to the documentation, they said Data directive is slower than method directive.

Really, it will be the same because it is the same code. However, you don’t want to put the code in an inefficient location.


If doing something that is specific for the UBAQ, then you should use the UBAQ Directive. Putting things into a Data directive exposes the code to possibly be run by anything that touches the data. For example, if you put a data directive on OrderRel table, it will execute whenever the order is modified (including order Entry, Job Entry, Shipments and Invoicing. But if you have an updatable BAQ that updates the OrderRel, and you have a UBAQ Method directive, it will only run as part of that Dashboard.
The point is that when you DEPLOY the dashboard, the system does compile the UBAQ BPM and it will run very efficiently.
There is one time that I did implement a data directive because of a Dashboard but that was because I was doing a customization that worked in both the standard UI, and also in a Dashboard. I wanted the same logic to apply in both places. In order to make it the same, I put the logic in a Data Directive.


Thanks Jason and Tim, this is very useful information. I will keep that in mind. I spent a lot of time moving code from one place to another recently.