Hi- I ran a drush up and did a quick and easy site-wide upgrade a few days ago. Just today, I noticed that all my webforms are gone (and db tables are empty). According to docs, db update should have preserved and upgraded the old ones.

Any insight and tips how I might most easily recover these forms? Perhaps uninstalling and installing the old version, copying over the relevant webform* tables from old db back, and upgrading again is a viable course?

CommentFileSizeAuthor
#6 webform_upgrade_types.patch1.24 KBquicksketch
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

texas-bronius’s picture

Update: Sorry for the noise-- db tables do exist, and I just had to enable Webforms on "webform" content type (in my case).

Thanks for the great module. Looking forward to learning about the new options.

texas-bronius’s picture

Status: Active » Fixed
quicksketch’s picture

Category: support » bug
Status: Fixed » Active

I actually had this problem on Lullabot.com when I updated it a few days ago. I think there must be something missing from our upgrade path that ensures the webform content type is webform-enabled when upgrading in some situations. I updated via drush also... I'd never seen this before in my manual testing.

Eric_A’s picture

I just did a quick test from 6.x-2.9 to 6.x-3.2 with one webform and a couple of submissions. I think I lost the e-mail to address. The update messages show dropping an email column without this data being moved first...?

The following queries were executed

webform module

Update #6301

ALTER TABLE {webform} ADD `confirmation_format` TINYINT NOT NULL DEFAULT 0

Update #6302

CREATE TABLE {webform_emails} ( `nid` INT unsigned NOT NULL DEFAULT 0, `eid` SMALLINT unsigned NOT NULL DEFAULT 0, `email` TEXT DEFAULT NULL, `subject` VARCHAR(255) DEFAULT NULL, `from_name` VARCHAR(255) DEFAULT NULL, `from_address` VARCHAR(255) DEFAULT NULL, `template` TEXT DEFAULT NULL, PRIMARY KEY (nid, eid) ) /*!40100 DEFAULT CHARACTER SET UTF8 */

ALTER TABLE {webform} DROP email

quicksketch’s picture

Title: upgrade from 6.x-2.? to 6.x.3.2 lost all webforms » Upgrade from 6.x-2.? to 6.x.3.2 does not webform-enable the "webform" content type

@Eric_A: The updates that are shown to you are only some of the queries, not all of them. Usually updates will use db_query() in places and update_sql() in others. Only the ones that run through update_sql() are actually displayed. However update_sql() doesn't support sanitizing or replacements, so db_query() is substituted instead in those places. If you find data actually missing, please open a separate issue.

I've clarified the title to reflect this specific problem.

quicksketch’s picture

Status: Active » Fixed
FileSize
1.24 KB

I haven't been able to pinpoint this issue, so I'm hoping this patch will correct it for new users upgrading. Please reopen if the problem crops on new migrations.

Status: Fixed » Closed (fixed)

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

truyenle’s picture

Hi quicksketch,

I try the 6.x-3.4 version and upgrade from 6.x-2.9 => the webform content type is lost!

Thanks
Truyenle

boblesurfeur’s picture

Hi,

I have the same issue.
I've upgraded from 6.x-2.x (schema version 6205) to 6.x-3.4 and I've lost the webform content type.

Any help ?

texas-bronius’s picture

Truyen, Bob-
As stated in my initial reply in #1 above, nothing was really lost, it just has to be reenabled on the content types you wish to use it (admin/settings/webform['Webform-enabled content types']).
-Bronius

Eric_A’s picture


I just did a quick test from 6.x-2.9 to 6.x-3.2 with one webform and a couple of submissions. I think I lost the e-mail to address.

The site where my update failed used the standard webform content type but with extra fields, in this case the one added by the print project. (6.x-1.10)

I haven't had the time to investigate if this may have had anything to do with it, but I thought I'd mention it here now.