The abuse_reasons table is not created on a fresh install. It is created during an upgrade though.

A temporary workaround is to force an upgrade on this module.

Comments

btmash’s picture

This one is very strange...I'll take a look into this for a fresh install to see what is going on.

btmash’s picture

Assigned: Unassigned » btmash

This one is very strange...I'll take a look into this for a fresh install to see what is going on.

niteman’s picture

Title: abuse_reasons table not created » error in install file

the reason seems to be that the install function does not contain the creation and filling code for that table. a copy and paste issue i think ;)

niteman’s picture

Title: error in install file » abuse_reasons table not created -> error in install file

I have to suggestions for this table, including the reasons in a localizable manner [t('reason')] and making arid field autoinc.

esllou’s picture

This is still an issue. I've had the same problem on the very latest version:

$Id: abuse.module,v 1.8 2007/03/26 21:25:45

Pink error box:

user warning: Table 'mysite_drupal.dru_abuse_reasons' doesn't exist query: SELECT COUNT(arid) FROM dru_abuse_reasons in /home/mysite/public_html/includes/database.mysql.inc on line 172.
schnizZzla’s picture

I have installed abuse days before, today I wanted to test it. Visiting the reasons config page I had the same error about not existing reasons table. After a quick look into the abuse.install, I saw that the reasons table is only created on UPDATE.
I have run drupal's update script, selecting abuse update version 1, and the script told me that no queries were executed (another bug) but as supposed the reasons table was created now. You only have to be careful, that you don't select other modules on the update page!

btmash’s picture

In the case of being in update, these were features being added from different tickets and for some reason, I thought a fresh install of a module would also run all the updates. I've changed the install file to execute the install and skip over the updates (should someone be updating and the table was already installed).

Regarding the 'no queries run' message, update_sql does not seem to play nicely with creating tables. As such, I called on drupal_set_message if everything ran properly. Should be in the next patch.

btmash’s picture

Status: Active » Closed (duplicate)

Fixed in other (previous) patches.