fixed test failure to be _cur_write_postges was _write_postgres
fix uninitialized variable schema for sqlite tests