Partial implementation of sqlite update and read