1

I have a DE named mock_data_only and its external key is set to the same string. I've tried doing a (SSJS) rows retrieve on this DE and wasn't able to do so. In cloudpage preview there's just a loading gif and if I looked into chrome's dev console, There was a 500 server error.

This is the script snippet I used.

Platform.Load("core", "1.1.5");
try {
    var subsDE = DataExtension.Init("mock_data_only");
    var filter = {
        Property: "isSent",
        SimpleOperator: "equals",
        Value: false,
    };
    var data = subsDE.Rows.Retrieve(filter);
    Write(Platform.Function.Stringify(data));
} catch (ex) {
    Write("An error has occurred: " + Stringify(ex));
}

However rows lookup worked as expected and I got the JSON string echoed

Platform.Load("core", "1.1.5");
try {
    var subsDE = DataExtension.Init("mock_data_only");
    var data = subsDE.Rows.Lookup(["isSent"], [false]);
    Write(Platform.Function.Stringify(data));
} catch (ex) {
    Write("An error has occurred: " + Stringify(ex));
}
2

I see there is extra comma at the end of last attribute pair Value :false, (which tells the system that it is not complete yet and expects another attribute pair) Can you please try after removing comma or try below code for filter variable.

var filter = {
        Property: "isSent",
        SimpleOperator: "equals",
        Value: false
    };

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.