title: Bash query sqlite
body: <p>sorry for the noob question. I'm trying to write a simple bash script, based on newsbeuter. Basically I'm trying to get the first 5 articles I haven't read yet, once I got them, I send them to my phone with pushover and I need so set them as read on newsbeuter.</p>
  
  <pre><code>#!/bin/bash --
  urls=$( sqlite3 /home/pi/.newsbeuter/cache.db &lt;&lt;END
    select url from rss_item where unread = 1 limit 5;
  END
  )
  </code></pre>
  
  <p>This is the first query. I send the message variable through the pushover api.
  Now I need to get how to update the table and set the articles as read. 
  Any ideas? (I'm totally new to bash syntax).
  I tried both to recreate a query like </p>
  
  <pre><code>UPDATE rss_item set unread = 0 where url = '$url' 
  </code></pre>
  
  <p>I looped it  but it didn't work, then I tried to make </p>
  
  <pre><code>`UPDATE rss_item set unread = 0 where url in ($urls)` 
  </code></pre>
  
  <p>but I keep getting errors I can't even understand! I really need a syntax lecture! </p>