Can you pass a generic BO name to process?

If you have questions or if you want to share your opinion about Aware IM post your message on this forum
Post Reply
bwalk
Posts: 54
Joined: Thu May 10, 2018 12:10 am

Can you pass a generic BO name to process?

Post by bwalk »

Good Day All,
I have a field 'Active' in all of my BO. Instead of deleting I want to do soft deletes by just changing this field from 'Yes' to 'No'. I can easily create an 'Operations with Records' entry to execute a process to do the update.
But in my process I have to specify the BO name then the attribute like so.
TaskCardDefaults.Active = 'No'
But this means I need a separate process for every BO.
Is there a way to structure this so I can do it in 1 process? I have tried 'THIS' but does not work.
Thanks
tford
Posts: 4238
Joined: Sat Mar 10, 2007 6:44 pm

Re: Can you pass a generic BO name to process?

Post by tford »

You could put the BOs in a BO Group and have that attribute be common to all in the group.
Tom - V8.8 build 3137 - MySql / PostGres
bwalk
Posts: 54
Joined: Thu May 10, 2018 12:10 am

Re: Can you pass a generic BO name to process?

Post by bwalk »

Great!! That works nicely.
Thanks tford
Jaymer
Posts: 2450
Joined: Tue Jan 13, 2015 10:58 am
Location: Tampa, FL
Contact:

Re: Can you pass a generic BO name to process?

Post by Jaymer »

there's database overhead associated with BOs in groups.
Don't know the extent of your application, but tables must be joined together (Union) for groups - if it were me, I'd examine SQL Profiler (if MS SQL) to see if you observe lots of "extra" reads when setting this field.

There's no overhead (only annoyance) in having to create 5,10,15 "kinda redundant" processes.
Click Here to see a collection of my tips & hacks on this forum. Or search for "JaymerTip" in the search bar at the top.

Jaymer
Aware Programming & Consulting - Tampa FL
bwalk
Posts: 54
Joined: Thu May 10, 2018 12:10 am

Re: Can you pass a generic BO name to process?

Post by bwalk »

Jaymer, this is important information.
Would the extra overhead be evident in normal usage of these BO or only when accessing via the BOG?
Thanks
Jaymer
Posts: 2450
Joined: Tue Jan 13, 2015 10:58 am
Location: Tampa, FL
Contact:

Re: Can you pass a generic BO name to process?

Post by Jaymer »

I agree its important.
But I can't tell you under what circumstances you're gonna feel it.
Whats your backend db?
Click Here to see a collection of my tips & hacks on this forum. Or search for "JaymerTip" in the search bar at the top.

Jaymer
Aware Programming & Consulting - Tampa FL
bwalk
Posts: 54
Joined: Thu May 10, 2018 12:10 am

Re: Can you pass a generic BO name to process?

Post by bwalk »

mySQL
Jaymer
Posts: 2450
Joined: Tue Jan 13, 2015 10:58 am
Location: Tampa, FL
Contact:

Re: Can you pass a generic BO name to process?

Post by Jaymer »

cant help you there. no idea how to do SQL monitoring there.
Click Here to see a collection of my tips & hacks on this forum. Or search for "JaymerTip" in the search bar at the top.

Jaymer
Aware Programming & Consulting - Tampa FL
bwalk
Posts: 54
Joined: Thu May 10, 2018 12:10 am

Re: Can you pass a generic BO name to process?

Post by bwalk »

If I notice any slowdown I will remove the BOG approach and go back to individual process.
Would it not make sense to have a way to pass the BO name into the process so that you could better utilize your code segments?
Jaymer
Posts: 2450
Joined: Tue Jan 13, 2015 10:58 am
Location: Tampa, FL
Contact:

Re: Can you pass a generic BO name to process?

Post by Jaymer »

bwalk wrote: Would it not make sense to have a way to pass the BO name into the process so that you could better utilize your code segments?
I hear what you’re saying, but I’ve never had that be an issue for myself. In your specific case, you are noticing that right now, because you have a field named the same exact thing across many BOs. I can’t say that happens to me a lot, so it’s never really been an issue.
Click Here to see a collection of my tips & hacks on this forum. Or search for "JaymerTip" in the search bar at the top.

Jaymer
Aware Programming & Consulting - Tampa FL
Post Reply