title: Transposing wide to long in SAS, without extra columns
body: <p>I'd like to transpose a dataset, but SAS insists on adding a new column, if the "by" column
  has multiple entries.</p>
  
  <p>So if I run</p>
  
  <pre><code>data test;
      input a b $ c $ ; 
  datalines;
  1  aaa bbb
  1  bbb bbb
  2  ccc ccc
  3  ccc ccc
  ;
  run;
  
  proc transpose data=test;
     by a;
     var b b;
  run;
  </code></pre>
  
  <p>I get a table with two columns that looks like this:</p>
  
  <pre><code>1   b   aaa bbb
  1   c   bbb bbb
  2   b   ccc 
  2   c   ccc 
  3   b   ccc 
  3   c   ccc 
  </code></pre>
  
  <p>What I'd like with a table that looks like this:</p>
  
  <pre><code>1   b   aaa
  1   c   bbb
  1   b   bbb
  1   c   bbb
  2   b   ccc 
  2   c   ccc 
  3   b   ccc 
  3   c   ccc   
  </code></pre>
  
  <p>So instead of adding columns, for each entry, I want SAS to add rows. Any ideas on how to do this?</p>
  
  <p>Just to be clear, this is a toy example! The dataset I'm working with has more columns.</p>