10
To fix the problem with "tdmlinks_purchase" table not being deleted during uninstall, add this at line 57 in xoops_version.php:
$modversion['tables'][9] = 'tdmlinks_purchase';
Also, in the SQL file, you can remove all the:
ENGINE=InnoDB
when you create database tables. If no Engine is defined, MySQL will take the default, which for the most current releases is InnoDB anyway.