3 of 3 people found this helpful
PIUnit is matching bstrModuleNameMask (I guess the naming is coming from the fact that PI Units are based on PI Modules).
There are two overloads of the PIUnitBatchSearch Method:
PIUnitBatchSearch Method (PIModuleDB object), and
PIUnitBatchSearch Method (PIModule object)
Based on the Search for PIUnitBatches chapter of the PI Server documentation, it looks like the way this search is implemented in PI SMT is that the first overload method is used if the PI Server name is set and PIUnit parameter is set to a name mask. The latter overload method is used if the PIUnit parameter contains a full path to the module that represents PIUnit.
Thank you. I deduced that it must be that way when it started giving me the same results as the search in SMT. I appreciate your reply.