Hi,

I just upgraded to the latest beta version by deactivating the older version on my site, deleting the old version's folder, and uploading the updated folder, however I now receive the following error all over my site.

user warning: Table 'taxonomy_treemenu' doesn't exist query: SELECT menu_name FROM taxonomy_treemenu in sites/all/modules/taxonomy_treemenu/taxonomy_treemenu.module on line 374.

Which refers to this function:

 static function allNames() {
    $names = array();
    $result = db_query("SELECT menu_name FROM {taxonomy_treemenu}");
    while ($tm = db_fetch_array($result)) {
      $names[] = $tm['menu_name'];
    }
    return $names;
  }

Does the upgrade path for this module require a complete uninstall before upgrading?

Thanks -

Comments

Apollo610’s picture

FYI, I had to completely uninstall the latest version of the module and reinstall and everything installed properly.

rcrowther’s picture

Hello,

Yes, the new BETAs require full reinstall. Until V5, Taxonomy Treemenu used what is called a Drupal database 'variable'. Drupal variables are so flexible that I stayed with them, as the module's needs kept changing so much that I couldn't stabilise the data the module needs to save. But one feature of V5 is that it has an entirely new basic structure to the code, and I felt I had enough of a plan to construct a proper database table. This seems to be the root of your problem.

Drupal procedure is to uninstall whenever new versions are out - anything but a second point upgrade, which should be just a bugfix. But I do it, and I'm sure lots of other people do - they try a quick swap to preserve their data.

If you are a GNU/Linux Unix user, and can at all stand the thought of the command line, I recommend drush. It strings command lines together to make a sort of packaging system for Drupal modules. It can save you hours of time and trouble when upgrading. It should be as well known as Views. There is an experimental Windows release too, but I can't speak for that.

As for fixing your installation, that depends on your version. I'm guessing it was a V4. In which case, don't worry about the old module. Try disabling then UNINSTALLING what you have. If that seems to destroy everything, you are making progress, so reinstall. The install/uninstall functions have been a bit of a thorn in the side of this module, as Drupal is a little crude in these respects, and the module kept changing rapidly. But V5 is much better at this (well, V4 was too), and also handles uninstalling a lot of legacy data.

And hello Apollo610 - good to see you back. Any thoughts? Does it fit your needs? I have a long list of hidden code to be implemented, so I'm easy to sway in some particular direction...

Rob

Apollo610’s picture

Hey Rob - thanks for the clarification... yeah, I try as much as possible to NOT uninstall just because I don't want to lose my data. Luckily, with all the modules I've used, I've been pretty lucky with not having to uninstall often, but got snagged on this. Not a problem though. :)

I'll let you know about my opinions once I dive back into it. With all the enhancements I have to toy around now and see how I can implement this badboy. One site I'm working on is ridiculously driven by taxonomy (like hundreds and hundreds of terms), so I'm hoping this works out as I expect. :)

Thanks again for all your hard work!

rcrowther’s picture

Just a quick comment on that then!

I've coded in c, and a friend has coded in C++, which I helped out on. I am sometimes in awe at how people code in PHP, really expensive code. But I'm not doing it down, because it's very fast to bash together. This would have taken forever in C++ (a year so far...)

Anyhow, I'm acutely aware that Taxonomy Treemenu may not be efficient - I coded for efficiency, but I've not tested. Upside is, though, if you or anyone else wants efficiency to be a priority, or run into performance issues, there may be substancial gains we can make quickly.

rcrowther’s picture

Status: Active » Fixed

In the sense, question answered.

Status: Fixed » Closed (fixed)

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