Click HERE to see how Saviynt Intelligence is transforming the industry. |
11/22/2023 07:59 AM
I am trying to set up an email template for analytics that includes the report name, report description, and conflict count. The analytic returns 42 rows, but it will not send the email out if I am including ${ANALYTICSDATA.size()} in the body of the email. If I remove it, the email sends fine. Can anyone see what I am doing wrong? Body text I am using:
Results for:
${analyticsConfig.analyticsName}
Row Count:
${ANALYTICSDATA.size()}
Report Description:
${analyticsConfig.description}
Solved! Go to Solution.
11/22/2023 01:49 PM
11/22/2023 02:26 PM - edited 11/22/2023 02:27 PM
@Saathvik I didn't find any error in the logs, and I don't want to upload logs here due to the potential for sensitive data to be shared by mistake.
The row count attribute is causing the failure for sure though. If I remove ${ANALYTICSDATA.size()} from the body message, it will send as expected. The analytic itself is not failing, either. It runs and generates a record in run history that I can view, so the failure is only in sending the email and only when I am trying to generate a row count.
Does anything with my syntax above look incorrect? I copy/pasted directly from the documentation, so I am not understanding why it is failing. Can someone try the snipped I pasted above and confirm whether its working for them?
11/22/2023 03:40 PM
@cgarwood : I have validated this, yes it is not working getting below error
groovy.lang.MissingPropertyException: No such property: ANALYTICSDATA for class: SimpleTemplateScript2071 at SimpleTemplateScript2071.run(SimpleTemplateScript2071.groovy:3) at com.saviynt.ecm.analytics.AnalyticsESService.notifyEmailToOwner(AnalyticsESService.groovy:2663) at com.saviynt.ecm.analytics.AnalyticsESService.emailAction(AnalyticsESService.groovy:16509) at com.saviynt.ecm.analytics.AnalyticsESService.doFileArchivalAndSendEmail(AnalyticsESService.groovy:14690) at com.saviynt.ecm.analytics.AnalyticsESService$_runControl_closure210_closure318.doCall(AnalyticsESService.groovy:14523) at com.saviynt.ecm.analytics.AnalyticsESService$_runControl_closure210.doCall(AnalyticsESService.groovy:14522) at java.lang.Thread.run(Thread.java:750)
11/22/2023 06:31 PM
use ${totalRecords}
11/27/2023 10:25 AM
This worked, thank you for the guidance.