title: Sybase ASE 15.0.2 - dynamically update statistics/ index statistics
body: <p>I am trying to update statistics to some of our tables whose names I receive as input to my procedure. But, I couldn't compile the procedure with the below code.</p>
  
  <pre><code>update index statistics @tableName
  </code></pre>
  
  <p>Aren't dynamic table names allowed? Or, would the below statement work?</p>
  
  <pre><code>select @statsCmd = 'update index statistics '+@tableName
  exec(@statsCmd)
  </code></pre>
  
  <p>Also, what are the notable differences between "update statistics" and "update index statistics"?</p>