BookmarkSubscribeRSS Feed
Leslie6860
Calcite | Level 5

This code works in EG and emails out fine. As soon as i put this into a user written transformation, nothing happens. The job runs with no errors but no email comes through.


Any Idea's?


Thanks, Les


FILENAME mail EMAIL TO=("xxx@xxx")

SUBJECT="Lunch Time Adherence - &sysdate." CONTENT_TYPE="text/html";

ODS LISTING CLOSE;

ODS HTML BODY=mail;

proc report data=sme_ad.lunch_adherance ;

     column

Agent

Lunch_Start

Formula_Act_Lunch_Start

Adherance;

   compute adherance;

     if adherance = "Adherent Lunch" then call define(_col_,"style","style={background=lightgreen}");

  if adherance = "Adherent Lunch - Calls Prevented" then call define(_col_,"style","style={background=green}");

  if adherance = "Non-Adherent Lunch - No Calls Prevented" then call define(_col_,"style","style={background=red}");

  if adherance = "Non-Adherent Lunch" then call define(_col_,"style","style={background=red}");

  if adherance = "Non-Adherent Lunch (Before Planned Lunch)" then call define(_col_,"style","style={background=red}");

   endcomp;

   run;

1 REPLY 1
LinusH
Tourmaline | Level 20

It would be great if you could have the example using SASHELP.CLASS so everyone could test it.

What does the log say?

I see no macro variables, but this is just for testing? Wouldn't be of much use to have it in a User Written Transform otherwise.

  • Are you using the same user?
  • Is it on the same Workspace Server?
  • What happens if you deploy the job an run it in batch?
Data never sleeps

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 1 reply
  • 650 views
  • 0 likes
  • 2 in conversation