title: Looping SQL query in MySQL Workbench
body: <p>trying to run a query in workbench that will cycle thru all of the site_ids and test my query against each of them. this should be easy but i'm missing something. </p>
  
  <pre><code>SET @user_id = 449;
  SET @getsites.site_id = 11;
  WHILE(@getsites.site_id &lt; 535) DO
       SELECT routine goes here
       SET @getsites.site_id = @getsites.site_id + 1;
  END WHILE;
  </code></pre>