uncommented writing temp to database