I have just installed the excelent looking new 2.x-dev version, but am getting the following error (after having created a simple 'on update' activity)

user warning: Unknown column 'nid' in 'field list' query: INSERT INTO activity_messages (uid, op, type, author_message, everyone_message, nid, created) VALUES (5, 'update', 'node', 'You updated node', 'admin updated node', 40, 1241120842) in /home/xxx/mysite.com/includes/common.inc on line 3422.

any ideas whether this is a bug, or if I missed someting at install?? thanks.

Comments

sirkitree’s picture

We've made some pretty major changes to the code in the last week which will be committed by the end of today and should fix this bug. I'll update you when the changes are committed so that you can test them out if you like. Thanks for your report :)

sirkitree’s picture

Status: Active » Fixed

New features have been committed - please read over the commit message here: http://drupal.org/cvs?commit=205382

Scott Reynolds’s picture

what u didn't mention sirkitree, is that you must reinstall the module because of the schema changes. This bug is case in point, as NID column was added later in dev cycle, it is used to prevent activity messages from showing up to people who don't have access to the node.

pisco23’s picture

I have un-selected the module from /admin/build/modules/list, and then removed it manually from sites/all/modules
I then uploaded today's dev version to the same modules folder and then activated it (again via /admin/build/modules/list).

I tried update.php just_in_case also.

Do I need to do anything else to get the database tables right?

I am now seeing different errors:

* user warning: Table 'dbase1.activity' doesn't exist query: INSERT INTO activity (uid, op, type, nid, created) VALUES (4, 'update', 'node', 42, 1241206364) in /home/.../mysite.com/includes/common.inc on line 3422.
* user warning: Unknown column 'message' in 'field list' query: INSERT INTO activity_messages (uid, message) VALUES (4, '') in /home/.../mysite.com/includes/common.inc on line 3422.
* user warning: Unknown column 'message' in 'field list' query: INSERT INTO activity_messages (uid, message) VALUES (0, 'admin updated node_title') in /home/.../mysite.com/includes/common.inc on line 3422.

If I am installing the module right I guess this is a 'bug report' and i should wait for a more stable version - if I am the cause of my problems - well, my apologies here and now ;-)

sirkitree’s picture

There were even more database changes today - but we think we finally have the schema to where it should be.

The process for reinstalling should be this:
Disable the module in admin/build/modules
Uninstall the module in admin/build/modules/uninstall (this removes all tables) **important**
Update the files in your sites/all/modules/activity folder
Enable the module in admin/build/modules (this re-installs the module with the new tables)

It looks like the step you were missing is the Uninstall.

Scott Reynolds’s picture

sure so uncheck it on admin/build/modules/list

then goto admin/build/modules/uninstall and check it

then go back to admin/build/modules and install it again

I use the devel module (drupal.org/project/devel) to easily resintall development modules on my local machine

pisco23’s picture

@sirkitree, @Scott Reynolds

Thanks for the help (and for the module ;-)) - the update and/or the missing 'uninstall' step (which I had never noticed before!) appears to have helped in the fix. Its working now. Looking forward to exploring the possibilities it unleashes !

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.