<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Creating N no of pdf files from N of obs in ODS and Base Reporting</title>
    <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Creating-N-no-of-pdf-files-from-N-of-obs/m-p/238352#M14842</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have two questions which I have listed below. Can anyone help me on it.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Let's say, I have a dataset named 'Sample' which is as follows:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Sample :&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Patient_No &amp;nbsp; Test1 &amp;nbsp; &amp;nbsp;Test2 &amp;nbsp; &amp;nbsp;Test3&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;101 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;20 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 30 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;70&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;102 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;22 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 32 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;55&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;103 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;30 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 50 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;88&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;104 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;50 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 29 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;63&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;105 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;45 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 60 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;72&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1. I want to &lt;STRONG&gt;create a pdf for each single observation&lt;/STRONG&gt;, which means I want to create 5 different Pdf files for 5 obs&amp;nbsp;from above dataset.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2. Also, I want to name to those files automatically. Each of the files must have the name as per value from it's&amp;nbsp;'&lt;STRONG&gt;Patient_No&lt;/STRONG&gt;' column. E.g. - pdf file for &lt;STRONG&gt;Patient_No - 101&lt;/STRONG&gt; must have the &lt;STRONG&gt;name&lt;/STRONG&gt; as '&lt;STRONG&gt;Patient 101&lt;/STRONG&gt;', for &lt;STRONG&gt;Patient_No 102&lt;/STRONG&gt; it should be '&lt;STRONG&gt;Patient 102&lt;/STRONG&gt;' and so on.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="line-height: 20px;"&gt;Can anyone confirm me that is it possible to program the above requirement using sas? If yes, then could you please help me on it?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="line-height: 20px;"&gt;Many Thanks in Advance.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="line-height: 20px;"&gt;Regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="line-height: 20px;"&gt;Vikrant&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 08 Dec 2015 18:05:25 GMT</pubDate>
    <dc:creator>VikrantSawatkar</dc:creator>
    <dc:date>2015-12-08T18:05:25Z</dc:date>
    <item>
      <title>Creating N no of pdf files from N of obs</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Creating-N-no-of-pdf-files-from-N-of-obs/m-p/238352#M14842</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have two questions which I have listed below. Can anyone help me on it.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Let's say, I have a dataset named 'Sample' which is as follows:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Sample :&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Patient_No &amp;nbsp; Test1 &amp;nbsp; &amp;nbsp;Test2 &amp;nbsp; &amp;nbsp;Test3&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;101 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;20 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 30 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;70&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;102 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;22 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 32 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;55&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;103 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;30 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 50 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;88&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;104 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;50 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 29 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;63&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;105 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;45 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 60 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;72&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1. I want to &lt;STRONG&gt;create a pdf for each single observation&lt;/STRONG&gt;, which means I want to create 5 different Pdf files for 5 obs&amp;nbsp;from above dataset.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2. Also, I want to name to those files automatically. Each of the files must have the name as per value from it's&amp;nbsp;'&lt;STRONG&gt;Patient_No&lt;/STRONG&gt;' column. E.g. - pdf file for &lt;STRONG&gt;Patient_No - 101&lt;/STRONG&gt; must have the &lt;STRONG&gt;name&lt;/STRONG&gt; as '&lt;STRONG&gt;Patient 101&lt;/STRONG&gt;', for &lt;STRONG&gt;Patient_No 102&lt;/STRONG&gt; it should be '&lt;STRONG&gt;Patient 102&lt;/STRONG&gt;' and so on.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="line-height: 20px;"&gt;Can anyone confirm me that is it possible to program the above requirement using sas? If yes, then could you please help me on it?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="line-height: 20px;"&gt;Many Thanks in Advance.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="line-height: 20px;"&gt;Regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="line-height: 20px;"&gt;Vikrant&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 08 Dec 2015 18:05:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Creating-N-no-of-pdf-files-from-N-of-obs/m-p/238352#M14842</guid>
      <dc:creator>VikrantSawatkar</dc:creator>
      <dc:date>2015-12-08T18:05:25Z</dc:date>
    </item>
    <item>
      <title>Re: Creating N no of pdf files from N of obs</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Creating-N-no-of-pdf-files-from-N-of-obs/m-p/238359#M14844</link>
      <description>&lt;P&gt;Many methods could be used to do it, here is call execute:&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data _null_;
   set sashelp.class(obs=3) end=last;
   if _n_ then call execute('ods pdf file=');
   call execute('"c:\temp\name_'||strip(name)||'.pdf" ;
                   proc print data=sashelp.class;
                   where name="'||strip(name)||'";
                   run;
                ');
if last then call execute('ods pdf close;');
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 08 Dec 2015 18:49:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Creating-N-no-of-pdf-files-from-N-of-obs/m-p/238359#M14844</guid>
      <dc:creator>slchen</dc:creator>
      <dc:date>2015-12-08T18:49:26Z</dc:date>
    </item>
    <item>
      <title>Re: Creating N no of pdf files from N of obs</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Creating-N-no-of-pdf-files-from-N-of-obs/m-p/238366#M14847</link>
      <description>&lt;P&gt;I like this approach. A little mod on your code will output one obs per pdf without 'where' condition.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data _null_;
   set sashelp.class(obs=4) end=last;
   if _n_ then call execute('ods pdf file=');
   call symputx('n',_n_);
   call execute('"h:\temp\name_'||strip(name)||'.pdf" ;
                   proc print data=sashelp.class(firstobs=&amp;amp;n obs=&amp;amp;n);
                   /*where name="'||strip(name)||';*/
                   run;
                ');
if last then call execute('ods pdf close;');
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 08 Dec 2015 19:26:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Creating-N-no-of-pdf-files-from-N-of-obs/m-p/238366#M14847</guid>
      <dc:creator>Haikuo</dc:creator>
      <dc:date>2015-12-08T19:26:34Z</dc:date>
    </item>
    <item>
      <title>Re: Creating N no of pdf files from N of obs</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Creating-N-no-of-pdf-files-from-N-of-obs/m-p/239034#M14867</link>
      <description>&lt;P&gt;Thank you very much Haikuo. It works perfectly.&amp;nbsp;I have another doubt.&lt;/P&gt;&lt;P&gt;I have three datasets named A, B and C which are as follows.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;STRONG&gt;Dataset A &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Dataset B &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Dataset C&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;PatientName Test1 Test2 Test3 &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;&lt;SPAN&gt;PatientName Test4 Test5 Test6 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;PatientName Test4 Test5 Test6&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;Alex &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;10 &amp;nbsp; &amp;nbsp; &amp;nbsp;20 &amp;nbsp; &amp;nbsp; &amp;nbsp;30 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;SPAN&gt;Alex &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;50 &amp;nbsp; &amp;nbsp; &amp;nbsp;60 &amp;nbsp; &amp;nbsp; &amp;nbsp;65 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;&lt;STRONG&gt;&amp;nbsp; &lt;/STRONG&gt;&amp;nbsp;Alex &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 63 &amp;nbsp; &amp;nbsp; &amp;nbsp;65 &amp;nbsp; &amp;nbsp; 70&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;Sachin &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;40 &amp;nbsp; &amp;nbsp; &amp;nbsp;50 &amp;nbsp; &amp;nbsp; &amp;nbsp;60 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;SPAN&gt;Sachin &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;&lt;SPAN&gt;30 &amp;nbsp; &amp;nbsp; &amp;nbsp;45 &amp;nbsp; &amp;nbsp; &amp;nbsp;55&lt;/SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Sachin &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;SPAN&gt;50 &amp;nbsp; &amp;nbsp; &amp;nbsp;60 &amp;nbsp; &amp;nbsp; &amp;nbsp;65 &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;Mark &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 30 &amp;nbsp; &amp;nbsp; &amp;nbsp;45 &amp;nbsp; &amp;nbsp; &amp;nbsp;55 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;M&lt;SPAN&gt;ark &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;SPAN&gt;40 &amp;nbsp; &amp;nbsp; &amp;nbsp;50 &amp;nbsp; &amp;nbsp; &amp;nbsp;60 &lt;/SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Mark &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;10 &amp;nbsp; &amp;nbsp; &amp;nbsp;20 &amp;nbsp; &amp;nbsp; &amp;nbsp;30 &amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;Ram &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;SPAN&gt;63 &amp;nbsp; &amp;nbsp; &amp;nbsp;65 &amp;nbsp; &amp;nbsp; 70&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Ram &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;SPAN&gt;40 &amp;nbsp; &amp;nbsp; &amp;nbsp;50 &amp;nbsp; &amp;nbsp; &amp;nbsp;60&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Ram &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;SPAN&gt;30 &amp;nbsp; &amp;nbsp; &amp;nbsp;45 &amp;nbsp; &amp;nbsp; &amp;nbsp;55&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Now I want to export data of the one patient from all 3 datasets into separate pdf (in pdf information from each dataset&amp;nbsp;should appear separate pdf pages). E.g. all the information from 3 datasets of patient let's say Alex should you exported into one pdf (separate page for each dataset) and so on.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Many thanks in advance for your help&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 12 Dec 2015 15:39:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Creating-N-no-of-pdf-files-from-N-of-obs/m-p/239034#M14867</guid>
      <dc:creator>VikrantSawatkar</dc:creator>
      <dc:date>2015-12-12T15:39:27Z</dc:date>
    </item>
    <item>
      <title>Re: Creating N no of pdf files from N of obs</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Creating-N-no-of-pdf-files-from-N-of-obs/m-p/239066#M14868</link>
      <description>&lt;P&gt;The output part can still be the same, only first merge/join the 3 tables by patientname, assume that they are 1:1 ratio,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;proc sq;&lt;/P&gt;
&lt;P&gt;create table want as&lt;/P&gt;
&lt;P&gt;select * from a, b, c&lt;/P&gt;
&lt;P&gt;where a.patientname=b.patientname and a.patientname=c.patientname&lt;/P&gt;
&lt;P&gt;;&lt;/P&gt;
&lt;P&gt;quit;&lt;/P&gt;</description>
      <pubDate>Sun, 13 Dec 2015 20:08:45 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Creating-N-no-of-pdf-files-from-N-of-obs/m-p/239066#M14868</guid>
      <dc:creator>Haikuo</dc:creator>
      <dc:date>2015-12-13T20:08:45Z</dc:date>
    </item>
    <item>
      <title>Re: Creating N no of pdf files from N of obs</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Creating-N-no-of-pdf-files-from-N-of-obs/m-p/239388#M14879</link>
      <description>Thank you so much.</description>
      <pubDate>Tue, 15 Dec 2015 18:48:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Creating-N-no-of-pdf-files-from-N-of-obs/m-p/239388#M14879</guid>
      <dc:creator>VikrantSawatkar</dc:creator>
      <dc:date>2015-12-15T18:48:23Z</dc:date>
    </item>
    <item>
      <title>Re: Creating N no of pdf files from N of obs</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Creating-N-no-of-pdf-files-from-N-of-obs/m-p/240128#M14946</link>
      <description>&lt;P&gt;thank you for your help.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But I want to create a pdf for each patient where each record of the patient from each dataset will be created on the separate page. Please consider my previous example. The records the patient let's say 'Alex' is present in 3 datasets. So I want to create a Single Pdf for patient 'Alex' where the exported pdf consists the observations from each dataset into separate pages within it. Means obs&amp;nbsp;for 'Alex' from Dataset A should on 1st page, obs from dataset B on 2nd page and so on.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you very much in advance.&lt;/P&gt;</description>
      <pubDate>Sat, 19 Dec 2015 06:34:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Creating-N-no-of-pdf-files-from-N-of-obs/m-p/240128#M14946</guid>
      <dc:creator>VikrantSawatkar</dc:creator>
      <dc:date>2015-12-19T06:34:26Z</dc:date>
    </item>
    <item>
      <title>Re: Creating N no of pdf files from N of obs</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Creating-N-no-of-pdf-files-from-N-of-obs/m-p/241165#M14984</link>
      <description>&lt;P&gt;I see you have already posted here two weeks ago, with less details, I must have overlooked, my bad. So condsider the following:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;
proc sort data=sashelp.class(drop=height) out=no_height;
	by name;
run;

proc sort data=sashelp.class(drop=weight) out=no_weight;
	by name;
run;

proc sort data=sashelp.class(drop=age) out=no_age;
	by name;
run;

data final;
	set no: indsname=dsname;
	by name;
	source=dsname;

	if _n_&amp;gt;6 then
		stop;
run;

data _null_;
	set final end=last;
	by name;

	if first.name then
		call execute('ods pdf file='||'"h:\temp\name_'||strip(name)||'.pdf";' );
	call execute('ods pdf startpage=now;
		proc print data=final(firstobs='||_n_||' obs='||_n_||');
		run;'
		);

	if last then
		call execute('ods pdf close;');
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Please note, since your request evolved, so I opted to choose a different merge strategy, rather, it is more like a sorted 'stacking', in order to show the 'source' of your obs.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Dec 2015 21:37:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Creating-N-no-of-pdf-files-from-N-of-obs/m-p/241165#M14984</guid>
      <dc:creator>Haikuo</dc:creator>
      <dc:date>2015-12-29T21:37:21Z</dc:date>
    </item>
  </channel>
</rss>

