There are a couple of ways to tell what version of WordPress is installed on your domain. The one I like to use is www.yourdomain.com/readme.html, if your wordpress is installed at the root of your domain. If your WordPress is installed in a subdirectory you need to instert that in the URL. This read me page will display towards the top the Installed WordPress version, if you replace all of the files at the same time. You can also log into your Admin section see the version of WordPress in the bottom right corner of the footer.
To determine the database version you will need to view your database contents. Navigate to the wp_options table (the prefix wp_ may differ in your database) and locate the field for db_version.
Here’s the list for up to version 2.8.4:
2.8.4 = 11548
2.8.3 = 11548
2.8.2 = 11548
2.8.1 = 11548
2.8 = 11548
2.7.1 = 9872
2.7 = 9872
2.6.5 = 8204
2.6.3 = 8204
2.6.2 = 8204
2.6.1 = 8204
2.6 = 8201
2.5.1 = 7796
2.5 = 7558
2.3.3 = 6124
2.3.2 = 6124
2.3.1 = 6124
2.3 = 6124
2.2.3 = 5183
2.2.x = 5183
2.2 = 5183
2.1.3 = 4773
2.1.x = 4773
2.1 = 4772
2.0.11 = 3441
2.0.x = 3441
2.0 = 3441
1.5.x = 2541
1.x = 2540
See the Installation FAQ on WordPress.com for further information.