title: How to dynamically update MySQL offset in php within android app
body: <p>Is there a way to dynamically assign <code>:val1</code> in this query: <code>$nextItemQuery = "SELECT * FROM</code>items<code>WHERE size = 0  LIMIT :val1 ,1";</code> in http request from android/java? 
  When I have to update rows in the table, I do this :</p>
  
  <pre><code>$nextItemQuery = "SELECT * FROM `items` WHERE picked = :picked  LIMIT 2,1";
  $query_params = array(
  
      ':picked' =&gt; $_POST['picked']
  );
  
   try {
          $stmt   = $db-&gt;prepare($nextItemQuery);
          $result = $stmt-&gt;execute($query_params);
      }
  </code></pre>
  
  <p>and in the app I add variable to Hashmap</p>
  
  <pre><code>HashMap&lt;String, String&gt; map = new HashMap&lt;String, String&gt;();
  
              map.put(TAG_PICKED, itPicked);
  </code></pre>
  
  <p>But since <code>LIMIT 2,1</code> is not a colum in the table I don't know how to access it and would really appreciate some help. Thanks</p>