Merge recent updates to Sqlite branch