title: How do I run two commands in a single line for loop in bash?
body: <p>Why can't I run two commands within a single line bash loop?</p>
  
  <pre><code>$ for i in {1..100} do printf %s "$(date)" ; mysql -uroot -e "SHOW SLAVE STATUS\G" | grep "Seconds_Behind_Master" ; sleep 10 ; done
  -bash: syntax error near unexpected token `mysql'
  </code></pre>
  
  <p>But this simple version works:</p>
  
  <pre><code>for i in {1..3}; do echo $i ; ls ; done
  </code></pre>