<?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 Remove duplicate labels when using break before in PROC REPORT in ODS and Base Reporting</title>
    <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Remove-duplicate-labels-when-using-break-before-in-PROC-REPORT/m-p/409958#M19768</link>
    <description>&lt;P&gt;Hi there,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm using a PROC REPORT to create a table on which I would like to apply a style on certain lines to highlight the change of group (visit in this case). I have found that a break after the visit variable generates exaclty the effect that I'm looking for, but the label of the visit appears now duplicated (in the grey background line, which is the one that I would like to keep, and on the white background line, which I would like to remove). Is there any easy way to avoid this duplicity?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The code of the PROC REPORT is part of a macro:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc report data=data2report2 nowindows headline style(header)={background=very light grey} missing split='*';
	column("&amp;amp;title." &amp;amp;timevar. ('Shift' shift) &amp;amp;stratavar., nval);
	define &amp;amp;stratavar./ '' across nozero order=internal;
	define &amp;amp;timevar./ f=&amp;amp;timevarfmt. '' group order=internal; 
	define shift/ f=shiftfmt. '' group order=internal;
	define nval/ '' group;
	break before &amp;amp;timevar. / summarize style=[background=very light grey];

	compute &amp;amp;timevar.;
		if &amp;amp;timevar. eq '99999' then do;
			call define (_row_,'style', 'style=[font_weight=bold]');
		end;
	endcomp;
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;And here is the table that I get where you can see the duplicates:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="tablebreak.png" style="width: 446px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/16382iE195EAD21BB8C325/image-size/large?v=v2&amp;amp;px=999" role="button" title="tablebreak.png" alt="tablebreak.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you for your help!!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best regards&lt;/P&gt;</description>
    <pubDate>Thu, 02 Nov 2017 18:19:32 GMT</pubDate>
    <dc:creator>emera86</dc:creator>
    <dc:date>2017-11-02T18:19:32Z</dc:date>
    <item>
      <title>Remove duplicate labels when using break before in PROC REPORT</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Remove-duplicate-labels-when-using-break-before-in-PROC-REPORT/m-p/409958#M19768</link>
      <description>&lt;P&gt;Hi there,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm using a PROC REPORT to create a table on which I would like to apply a style on certain lines to highlight the change of group (visit in this case). I have found that a break after the visit variable generates exaclty the effect that I'm looking for, but the label of the visit appears now duplicated (in the grey background line, which is the one that I would like to keep, and on the white background line, which I would like to remove). Is there any easy way to avoid this duplicity?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The code of the PROC REPORT is part of a macro:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc report data=data2report2 nowindows headline style(header)={background=very light grey} missing split='*';
	column("&amp;amp;title." &amp;amp;timevar. ('Shift' shift) &amp;amp;stratavar., nval);
	define &amp;amp;stratavar./ '' across nozero order=internal;
	define &amp;amp;timevar./ f=&amp;amp;timevarfmt. '' group order=internal; 
	define shift/ f=shiftfmt. '' group order=internal;
	define nval/ '' group;
	break before &amp;amp;timevar. / summarize style=[background=very light grey];

	compute &amp;amp;timevar.;
		if &amp;amp;timevar. eq '99999' then do;
			call define (_row_,'style', 'style=[font_weight=bold]');
		end;
	endcomp;
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;And here is the table that I get where you can see the duplicates:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="tablebreak.png" style="width: 446px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/16382iE195EAD21BB8C325/image-size/large?v=v2&amp;amp;px=999" role="button" title="tablebreak.png" alt="tablebreak.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you for your help!!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best regards&lt;/P&gt;</description>
      <pubDate>Thu, 02 Nov 2017 18:19:32 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Remove-duplicate-labels-when-using-break-before-in-PROC-REPORT/m-p/409958#M19768</guid>
      <dc:creator>emera86</dc:creator>
      <dc:date>2017-11-02T18:19:32Z</dc:date>
    </item>
    <item>
      <title>Re: Remove duplicate labels when using break before in PROC REPORT</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Remove-duplicate-labels-when-using-break-before-in-PROC-REPORT/m-p/410210#M19776</link>
      <description>&lt;P&gt;proc report ...... out=temp&amp;nbsp; /*Check the _BREAK_ variable in TEMP table*/&lt;/P&gt;
&lt;P&gt;......&lt;/P&gt;
&lt;P&gt;compute nval;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;if missing(_break_) then &amp;amp;timevar='&amp;nbsp; ';&lt;/P&gt;
&lt;P&gt;endcomp;&lt;/P&gt;</description>
      <pubDate>Fri, 03 Nov 2017 13:32:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Remove-duplicate-labels-when-using-break-before-in-PROC-REPORT/m-p/410210#M19776</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2017-11-03T13:32:36Z</dc:date>
    </item>
    <item>
      <title>Re: Remove duplicate labels when using break before in PROC REPORT</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Remove-duplicate-labels-when-using-break-before-in-PROC-REPORT/m-p/410337#M19777</link>
      <description>&lt;P&gt;Thank you for your quick response!!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I just wanted to add to your solution that if your &amp;amp;timevar variable is numeric you must add . = ' ' in the predefined format to avoid a point to appear in your final proc report.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks again!&lt;/P&gt;</description>
      <pubDate>Fri, 03 Nov 2017 16:37:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Remove-duplicate-labels-when-using-break-before-in-PROC-REPORT/m-p/410337#M19777</guid>
      <dc:creator>emera86</dc:creator>
      <dc:date>2017-11-03T16:37:04Z</dc:date>
    </item>
  </channel>
</rss>

