We have a BOM query that we pass the part number and rev as parameters that the user enters. Our users have requested we pre-fill the rev with the max rev after entering the part. I know I can use my max query to get the max rev, but how do I tie it to the part number entered? I have it set like this, but I don’t know how to have it refresh the Revision after the user puts in the part number. I want to display it so they can change it if they don’t want the max revision.
I’m not aware of any way to pre-fill a BAQ parameter dynamically.
One alternative would be change the query to use the Part’s latest Revision by default if the Rev
Parameter is empty, and only use another revision if the user specifies it in the Parameter. It wouldn’t be pre-filled, but it would achieve a similar result with the user not needing to enter a rev to get the latest.
I guess I am not as BAQ savvy as I thought. How do you tell it to use a query to get the max rev when the parameter is empty or use the parameter when it is filled in? I use the Table Criteria to filter it by the parameter, but not sure how to fill the parameter as a result of another query. Subquery criteria may be another option but I’m not sure how to do that either.
You would have to use a BPM dataform…
and customize that to pass into the parameter.
It’s gross and those dataforms don’t move from one database right when deploying from dev to production.
But once it’s set up, it’s ok.
The other thing I was trying was to customize the tracker on the dashboard to add an event when they changed the part number to go get the max, but for some reason it doesn’t like the csm part of csm.GetNativeControlReference. Anyone know what reference I need for that? I would have though the form customizations would be the same but I guess not…
You aren’t trying to do it in the dashboard maintenance are you? If you are, don’t. That customization is severely limited and causes more problems than it’s worth.
What you need to do it deploy your dashboard, then do a customization on the menu item. Then all the normal stuff will work, like csm…
I was trying that but I will change courses and go for the menu item. Thanks.
Revisiting this again. I tried using the tracker view to fill the data the way I want, but the issue appears to be when using a CTE query (building a BOM) you can’t use the tracker to filter, you have to use parameters. Is that correct? If I use the parameters I get results from the query, but if I try using the same query without parameters and just try the tracker it never returns and I end up stopping Epicor.
I know I can’t customize the parameter form, so the question is how do I get the tracker view to pass the filter to a CTE query?
Correct. This is the one area where you can’t use simple filter.
You can do it it with a BPM data form, but it’s kind of complicated. I’ve done it, but it’s hard to explain.
You can prefill in Query Parameters with BAQ Markup Syntax. As long as you have the PartNum you should be able to use Part.PartNum in your Values BAQ.
Second if you mark the BAQ a Updatable BAQ you can do BPMs on it. Do stuff on FieldChange Events.
–
Third if you make a BAQ MyBaqParams
and the Params is just Calculated_Fields you can mark it Updatable, assign it in 10.2.600 as Main BAQ in a Dashboard and Publish Parameters (not filters) to the other BAQs such as MyBaqHead
and MyBaqDetail
–
BAQs are the most powerful thing Epicor has, I hope it stays that way in Kinetic You can get pretty crazy with UBAQ and BPMs or you can leverage simple tools yet still do wild stuff.
← One just wasn’t enough
Absolutely.
Then you combine functions and baqs, and you’ve got it all.
I am still not getting something. Maybe if I explain a bit more someone can tell me which type of solution would be best.
I have a BOM dashboard based on a CTE query. Right now the user puts in the part number and part revision. Our team would like it to auto fill the revision with the latest rev but also give them the ability to make it a different one. I have a query that gets the max revision for the part. I know that with the CTE the part and rev must be passed as parameters or the CTE query doesn’t run.
Which would be the best way to have the user enter the part, the query run to get the max rev, then have the parameters passed to the CTE BOM query?
Maybe this would work for you. You can set parameters using the publish and subscribe. So you can make a small “selector” baq, then publish the part number and revision, then in the CTE grid you can subscribe to those values.
To publish, click on properties on the query (not the grid) and you’ll see a publish tab. Click on the fields you want to send to your CTE.
On the CTE click on the properties of the BAQ (again, not the grid) and go to the parameters tab. You’re parameters should show up there, and you can assign your published values to parameters.
I believe that should do what you want. And no complicated customizations to make it work!
Which version of Epicor 10 are you on?
ooohhh!! good point. The parameters thing is relatively new. I forgot about that.
We are on 10.2.600.
I guess check and see if it has that. I was about that time it came out with this feature, but I would guess your version doesn’t have that.
The parameters are in my version but it still isn’t doing what I want. I used my query to get the max rev, which prompts for the part number. After entering the part number it automatically gets the max rev and fills the IBOM part of the dashboard (linked with the published fields). The problem is I want it to be a 2-step process. The user enters the part number, the first query returns the rev, then the user can change it or leave it with the max and do the refresh to get the proper IBOM.
I have the basics of it working from a customized form but the fact that the CTE query has to have parameters is keeping it from working.
Make the first selection query return a list of part numbers and revs. Then publish both, and use both of them in the parameters.
Sort your selection query so that the “max” (however you define it) is listed first. Then when they refresh, it should publish the first row. If they want to look at another rev, they just pick a different row.