I have a custom Drupal 6 module (based on this issue) that puts some custom date and time formats into the date_format_types
table and then can be accessed from /admin/settings/date-time/formats
. This works nicely but I'd like to remove these from that table if the module gets uninstalled.
In my module's .install file, I tried this code:
<?php
/**
* Implementation of hook_uninstall().
*/
function eventdates_custom_uninstall() {
db_query("DELETE FROM {date_format_types} WHERE type LIKE 'eventdates_custom_date_%'");
}
This does not seem to work and the entries that had been added do not get removed from the date_format_types table when I uninstall the module but I am pretty sure I have the query correct.