<?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 Re: how to get the name of the extra variable into a proc compare in SAS Enterprise Guide</title>
    <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/how-to-get-the-name-of-the-extra-variable-into-a-proc-compare/m-p/962558#M45874</link>
    <description>&lt;P&gt;I see no difference other than variable LABEL.&amp;nbsp; Based on the PROC COMPARE output.&lt;/P&gt;</description>
    <pubDate>Mon, 24 Mar 2025 21:26:45 GMT</pubDate>
    <dc:creator>data_null__</dc:creator>
    <dc:date>2025-03-24T21:26:45Z</dc:date>
    <item>
      <title>how to get the name of the extra variable into a proc compare</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/how-to-get-the-name-of-the-extra-variable-into-a-proc-compare/m-p/962557#M45873</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am adding a new variable into a spde dataset, thereafter I am doing a proc compare.&lt;/P&gt;
&lt;P&gt;But I am getting different variables length while it is not the case.&lt;/P&gt;
&lt;P&gt;Can I trust my new datasets? Why are we getting those results?&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;libname  BANDE1 spde '/.../Temp/Alain/test/Classic/gc/auto';
libname  BANDE2 spde '/.../Temp/Alain/test/Classic/gc/habi';
libname  BANDE3 spde '/.../Temp/Alain/test/Classic/gc/entr';

libname  BANDE4 spde '/.../Temp/Alain/test/Classic/gc2/auto';
libname  BANDE5 spde '/.../Temp/Alain/test/Classic/gc2/habi';
libname  BANDE6 spde '/.../Temp/Alain/test/Classic/gc2/entr';

%let co=gc;
%let moisc=feb;
%let year=2025;

Data BANDE4.&amp;amp;CO._AUTO_PRM&amp;amp;MOISC.&amp;amp;YEAR. ;
ORGNL_SAS_DS_ROW_NBR=_N_;
set BANDE1.&amp;amp;CO._AUTO_PRM&amp;amp;MOISC.&amp;amp;YEAR. ;
run;

/****** Bande2 for Property *****/

Data BANDE5.&amp;amp;CO._PROP_PRM&amp;amp;MOISC.&amp;amp;YEAR. ;
ORGNL_SAS_DS_ROW_NBR=_N_;
set BANDE2.&amp;amp;CO._PROP_PRM&amp;amp;MOISC.&amp;amp;YEAR. ;
run;

/****** Bande3 for Enterprise *****/
data BANDE6.&amp;amp;CO._CNA_PRM&amp;amp;MOISC.&amp;amp;YEAR. ;
ORGNL_SAS_DS_ROW_NBR=_N_;
set BANDE3.&amp;amp;CO._CNA_PRM&amp;amp;MOISC.&amp;amp;YEAR. ;
run;

/****** The proc compare steps *********/

proc compare base=bande1.&amp;amp;CO._AUTO_PRM&amp;amp;MOISC.&amp;amp;YEAR. compare=BANDE4.&amp;amp;CO._AUTO_PRM&amp;amp;MOISC.&amp;amp;YEAR. 
listvar;
run;
proc compare base=bande2.&amp;amp;CO._prop_PRM&amp;amp;MOISC.&amp;amp;YEAR. compare=BANDE5.&amp;amp;CO._prop_PRM&amp;amp;MOISC.&amp;amp;YEAR. 
listvar ;
run;
proc compare base=bande3.&amp;amp;CO._CNA_PRM&amp;amp;MOISC.&amp;amp;YEAR.  compare=BANDE6.&amp;amp;CO._CNA_PRM&amp;amp;MOISC.&amp;amp;YEAR.  
listvar ;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Extract of the log:&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="alepage_1-1742850232558.png" style="width: 1077px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/105612iFC7C8C66896F6BA6/image-dimensions/1077x440?v=v2" width="1077" height="440" role="button" title="alepage_1-1742850232558.png" alt="alepage_1-1742850232558.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 24 Mar 2025 21:04:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/how-to-get-the-name-of-the-extra-variable-into-a-proc-compare/m-p/962557#M45873</guid>
      <dc:creator>alepage</dc:creator>
      <dc:date>2025-03-24T21:04:19Z</dc:date>
    </item>
    <item>
      <title>Re: how to get the name of the extra variable into a proc compare</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/how-to-get-the-name-of-the-extra-variable-into-a-proc-compare/m-p/962558#M45874</link>
      <description>&lt;P&gt;I see no difference other than variable LABEL.&amp;nbsp; Based on the PROC COMPARE output.&lt;/P&gt;</description>
      <pubDate>Mon, 24 Mar 2025 21:26:45 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/how-to-get-the-name-of-the-extra-variable-into-a-proc-compare/m-p/962558#M45874</guid>
      <dc:creator>data_null__</dc:creator>
      <dc:date>2025-03-24T21:26:45Z</dc:date>
    </item>
    <item>
      <title>Re: how to get the name of the extra variable into a proc compare</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/how-to-get-the-name-of-the-extra-variable-into-a-proc-compare/m-p/962584#M45875</link>
      <description>&lt;P&gt;I would like to know why when we add just one more variable like orgnl_sas_ds_row_nbr, the label into the new dataset become blank instead of transfering the previoius label.&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;How to correct that issue?&lt;/P&gt;</description>
      <pubDate>Tue, 25 Mar 2025 12:49:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/how-to-get-the-name-of-the-extra-variable-into-a-proc-compare/m-p/962584#M45875</guid>
      <dc:creator>alepage</dc:creator>
      <dc:date>2025-03-25T12:49:49Z</dc:date>
    </item>
  </channel>
</rss>

