I wrote a custom module to which modifications need to be made.
The major change is that I need to add a column to one of the custom tables.
My TAS.Info file looks like this (originally I did not have a version attribute. This was added while trying to get the update to work):
; $Id$
name = TAS
description = A module that allows TAS corrections.
package = TAS
version = 1
core = 6.x
dependencies[] = date_popup
dependencies[] = jstools
I added this function in my TAS.install file:
function TAS_update_1() {
$ret = array();
db_add_field($ret, 'tas_queue', 'manager_update_date', array('type' => 'datetime', 'not null' => FALSE));
return $ret;
}
I also added the following entry in the TAS.install file in the TAS_schema hook:
'manager_update_date' => array
(
'type' => 'datetime',
'not null' => FALSE
)
From this point I am not exactly sure what to do to make the update run.
I tried going to http://localhost/drupal/update, however my module was not listed there. I also checked the module section and can not find how to run the update.
Any help would be greatly appreciated.
Comments
You may need to let Drupal
You may need to let Drupal know the module has an update to be made.
Still not working
Here are the changes I made (just to be sure ):
TAS.info (I also tried with version = 6.x-1.1):
TAS.install:
Do I need to restart something or uninstall/reinstall someting ??
Sorry for the obvious
Sorry for the obvious question but have you ran through update.php?
Think So
I assume you mean to run http://localhost/drupal/update thru the browser?
It's in your Drupal root so
It's in your Drupal root so I'd guess either:
When I run that I see several
When I run that I see several modules (but not my custom module) with the abillity to choose an update number. If I can get mine to show up here I will be in heaven.
Understood. The module should
Understood. The module should always be listed with all available updates so you could in theory select a previous update to rerun.
So to confirm is your module list at all on update.php? If not is the module enabled and does it list on the modules page admin/build/modules?
It is not listed in the
It is not listed in the screens you get to when you run update.php. It is listed in the admin/site building/modules and is enabled.
Cool, I managed to replicate
Cool, I managed to replicate you problem by using a module with an upper case name.
I suggest moving to a lowercase name. However when I did this I had to manually remove the record from the system table so do backup your database first.
It's apparently a bug in the
It's apparently a bug in the update system that won't find modules with capital letters in their names. A few people have been reporting this over the last couple of months.
YOU ROCK! That fixed it!
YOU ROCK! That fixed it!
By Name do you mean the
By Name do you mean the machine name or the human readable name in the .info file?
The machine name.
The machine name.
Fixing bug
To fix the bug and allow upper case letters in your module name (to work with update.php), the bug in includes/install.inc should be fixed as follows:
Cheers!