fix close rows warning.
adding test match.
adding last db connection.