title: Using macro to repeat aggregate command
body: <p>I have a dataset with columns parcomm, subcomm, ccs, prov, data. I'd like to have aggregate result of data for the first four columns. I used spss code as stated below</p>
  
  <pre><code>DEFINE myvars (arg=TOKENS(4)).
  aggregate 
  /OUTFILE=* MODE=ADDVARIABLES 
  /BREAK=!arg
  /sum_!arg=sum(data).
  !ENDDEFINE.
  
  myvars parcomm subcomm ccs prov.  
  </code></pre>
  
  <p>The error shows</p>
  
  <blockquote>
    <p>Error # 10933 in column 2.  Text: parcomm  The definition of a new
    variable on the AGGREGATE command must be terminated by a slash. 
    Execution of this command stops.</p>
  </blockquote>
  
  <p>When I tried just one token, I have the following error:</p>
  
  <pre><code> DEFINE myvars (arg=!TOKENS(1)). 
   aggregate  /OUTFILE=* MODE=ADDVARIABLES  
   /BREAK=!arg   
   /sum_sum=sum(data). 
   !ENDDEFINE. 
   myvars arg=prov.  
  </code></pre>
  
  <blockquote>
    <p>Error # 10934 in column 48.  Text: prov.  
    The AGGREGATE command specifies an unknown existing variable name.
    Execution of this command stops.</p>
  </blockquote>
  
  <p>How should I fix the problem?</p>