SQLiteStorage: improvement on the GetAndModify methods

SQLiteStorage: improvement on the GetAndModify methods