I have a Drupal 6 installation for my website, and over time, without any doing on my part, I started getting an error, below:

user warning: Table 'pharmtec_pharmtechinc.xmlsitemap' doesn't exist query: SELECT * FROM xmlsitemap WHERE type = 'node' AND id IS NULL in /home/pharmtec/public_html/sites/all/modules/xmlsitemap/xmlsitemap.module on line 544.

I have no clue what the issue is. I did find out, though, that it does come up for both existing and new pages.

I'm stuck because I can't update the content of the site. When I add information and preview, it shows all the source code for the entire page, rather than just the text. :(

Thanks for any help you can provide.

2 Answers 2


If ok with some code, you could also try running


and that should recreate the xmlsitemap tables, backup db first.

more info:


The table seems to be related to XMLSitemap Module, are you using this module for anything? if not simply disable it and this error will go away, if you are then something has gone wrong with the module configuration/your database and it needs fixing.

If you need XMLSitemap enabled, try first running update.php and make sure you are on the latest stable version of XMLSitemap.

  • 1
    the prefix on the table also suggests you are on a shared database so it is possible so other site corrupted mysql or something. but, if running update.php doesn't fix things, you will need to go in and re-create the table. if your admin interface still works, disabling the module and then uninstalling it will remove all the database tables it uses. then enabling it back again will remake all of them.
    – Jimajamma
    Feb 7, 2013 at 16:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.