Hi All,
Can some one share Event scripts to check import , validate and export status,
I am using below script, it is triggering mails, but not sure how to verify the status import , validate and export, can you help me on this.
import smtplib
location = str(fdmContext["LOCNAME"])
rule = str(fdmContext["RULENAME"])
period = str(fdmContext["PERIODNAME"])
category = str(fdmContext["CATNAME"])
filename = str(fdmContext["FILENAME"])
sender = "xxx.com"
receivers = "xx.com"
message = """From: user
To: Business Users
Subject: Successful Data Load for Location """ + location + """ Rule """ + rule + """
The following data extract file has been loaded successfully for
1. Location: """ + location + """
2. Rule: """ + rule + """
3. Period: """ + period + """
4. Category: """ + category + """
"""
try:
smtpServer = smtplib.SMTP('xxx.beis.com', 25)
smtpServer.sendmail(sender, receivers, message)
print "Successfully sent email"
smtpServer.quit()
except Exception, e:
print "Error: unable to send email: " + str(e)
Thanks,
MSR