🚀 Welcome to MDriven Learn –  Don’t miss the latest Release Notes.
OCLOperators ExecutePS

NOTE: Consider using <Class>.PSEval instead of this for new development

selfVM.ExecutePS() enables you to use the power and speed of the database to find a subset of objects of a certain type in a ViewModel.

In the example below, ExecutePS is used to look up License objects with PS (avoiding traversing all existing objects in memory).

The PS-evaluated expression (translated to SQL and executed in DB) is defined in a ViewModelColumn of its own that is not referenced by any UI.

ExecutePS will look for the MaxFetch taggedvalue on the root-level column and limit the returned values.

See also: How_to_use_the_ExecutePS_function_in_selfVM