function does_database_have_data()
{
global $wpdb;
$tableprefix = $wpdb->prefix;
$simple_history_table = SimpleHistory::DBTABLE;
$simple_history_context_table = SimpleHistory::DBTABLE_CONTEXTS;
$sql_data_exists = "SELECT id AS id_exists FROM {$tableprefix}{$simple_history_table} LIMIT 1";
$data_exists = (bool) $wpdb->get_var($sql_data_exists, 0);
return $data_exists;
}