Has anyone have success of using SSJS filters to exclude data that contains a particular string?
I am trying to get a list of Marketing Cloud users that the AccountUser.Name doesn't contain the word 'user'.
Sadly,notExistsInString
and notContains
only for the DataFilter. I got the following error when I used it
StatusError: "notExistsInString" is not a valid SimpleOperator for a retrieve Filter.
var filterNotAppUser = {
Property: "Name",
SimpleOperator: "notExistsInString",
Value: "user"
};
var prox = new Script.Util.WSProxy();
var cols = ["ID", "Name", "Email","ActiveFlag"];
var myUsers = prox.retrieve("AccountUser", cols, filterNotAppUser);
Write("Status" + myUsers.Status);