Added waiting for sqlite file