I have the following code:
<script runat="server">
Platform.Load("Core","1.1.1");
try{
var logDE = DataExtension.Init("testDE");
throw "this is an error";
logDE.Rows.Add({"c1":"success"});
}
catch(e)
{
logDE.Rows.Add({"c1":e});
}
</script>
I run this inside Automation Studio. However, it should throw an error and use the catch block.
The catch block will add a row to the DE "testDE" with "this is an error".
This is my theory, but I just get an error during execution without any information of why.
To rule out any issues with the DE I have removed the throw and the DE is populating with "success".
Why is my catch block not working?