The Trigger_CausedByProduct() function is used in a trigger processing procedure of a database trigger to find out which product caused the trigger to activate.
Trigger_CausedByProduct()
• None
An integer containing the ID of the product that caused the trigger to activate. The value -1 is returned if the trigger is activated by a script that is running in the background. Currently, you can’t find what product caused a trigger if processing is occurring in the background.
This function is useful if you want to selectively run a database trigger processing script based on the product that caused the trigger to activate.