I am porting a module to Drupal 7. The module has hook_update_N()
functions called from hook_install()
. There are some insert queries made inside one of the hook_update_N()
functions. But my hook_update_N
function is not running. Is there any way to explicitly invoke hook_update_N
functions?
I know my question is almost same as this How to get hook_install() to run all hook_update_N()?. But I don't understand how hook_update_N()
is called. I have run updates in my Drupal site which I think also run updates of custom modules but it seems hook_update_N()
is not getting triggered. Because, I have added error_log()
function inside hook_update_N()
but the log file is empty.