BookmarkSubscribeRSS Feed
Obsidian | Level 7

I am trying to create a stored process that the webout varies according to what the user selects, I created this code to test but it doesn't work, could someone tell me why? 


Thanks in advance


%global M_Opt_FT;
/*"User will pass this parameter by another stored process, here i just created him to debug"*/ %let M_Opt_FT=NOVO; %macro test; %if "&M_Opt_FT" = NOVO %then %do; data _null_; /* if "&M_Opt_FT" = NOVO then do;*/ file _webout; put '<html>'; put '<body>'; put '<HEAD><TITLE>FAST TRACK</TITLE></HEAD>'; /* put '<FONT face=Arial size=2 COLOR="#000000">;<B>BANCO ABC BRASIL</B></FONT>';*/ put '<FORM action="" enctype="multipart/form-data" method="post">'; put '<fieldset>'; put '<legend>FAST TRACK</legend>'; put '<B>CRC empresa a ser pesquisada:</B><BR>'; put '<input type="text" name="M_Crc_Cliente"><BR><BR>'; put '<B>Data balanço mais recente:</B><BR>'; put '<input type="date" name="M_Bal_Recente"><BR><BR>'; put '<B>Data balanço mais antigo:</B><BR>'; put '<input type="date" name="M_Bal_Antigo"><BR><BR>'; put '<INPUT name="_program" type=hidden value="/BancoABC/Publico/StoredProcedure/fastTrack_2">'; put '<INPUT name=_debug type=hidden value=0>'; put '</select><br><br>'; put '<INPUT name=B1 type=submit value=ENVIAR>'; put '</fieldset>'; put '</FORM>'; put '<BR><BR>'; put '</body></html>'; run; %end; /* not simply closing the prior please wait */ %mend test; %test;
Rhodochrosite | Level 12

What problem are you experiencing when you run the code?


You might want to try omitting the STPBEGIN/STPEND macro invocations if you are using them.  In some cases SAS Enterprise Guide automatically adds these macro invocations, so that is something else to check.


Vince DelGobbo




Registration is open! SAS is returning to Vegas for an AI and analytics experience like no other! Whether you're an executive, manager, end user or SAS partner, SAS Innovate is designed for everyone on your team. Register for just $495 by 12/31/2023.

If you are interested in speaking, there is still time to submit a session idea. More details are posted on the website. 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Get the $99 certification deal.jpg



Back in the Classroom!

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

View all other training opportunities.

Discussion stats
  • 1 reply
  • 2 in conversation