Failed Upgrade 4.6.4 to 4.6.5 Joomla 2.5 & 3.4
Civi 4.6.5 adds a new table "civicrm_cxn".  Your upgrade is failing because it's trying to add this table, but it already exists.

Usually this happens when you attempt an upgrade which didn't complete for whatever reason, then attempt a second upgrade without doing a DROP DATABASE and CREATE DATABASE command.  Even though you may have restored a backup, newly-created tables will still be present.

The most "correct" way to handle this is to do a DROP DATABASE command for your Civi database, then CREATE DATABASE and load in your backup.  That said, I suspect you can get away with blowing away the new table and running the upgrade again; try DROP TABLE civicrm_cxn; in MySQL and see if the upgrade works.  Make a backup first, of course!