Hello. I've added a new field to one of my Webforms and it isn't showing up in the list of available fields in the View or the Data table. I tried adding it to the table in "/admin/structure/data/edit" and I get an error.

I decided to go for the nuclear option and export the view, delete the view, drop the table, disconnect the webform association on /admin/content/webform/mysql, and start from scratch. I was able to make the association again, but now my View import is giving me the following error:

Relationship handler my_webform.sid is not available.

Anyone have any clue?

Comments

loopy1492’s picture

I was able to restore the view with a backup, thankfully, but I still have no idea why I get an error when I try to add a field to the data table.

I added the following field to my form:

Label: "Date Letter Sent"
Field Key: "date_letter_sent"

When I go into the view and into the following location, the field isn't represented:

/admin/structure/data/edit/my_webform

So I try to use the little form at the bottom of that page to add a "date_letter_sent" field, but it throws this error:

"Error adding field."

And no log message is generated, unfortunately, so I have no idea what is going on here. Can anyone help me figure out what to do? There don't seem to be any other issues or documentation on how to handle this.

Thanks

loopy1492’s picture

So, I went into DataTable.inc and forced it to print the actual error ($e). The error is:

"Cannot add field: field already exists"

Which is extremely odd, because it's not showing up in the list.

Could this have something to do with the Schema mismatch? Is there a way to fix that?

loopy1492’s picture

So I Disowned the table, and then Adopted it again.

The field showed up, but my View was TRASHED. All the Relationships had been obliterated. I tried restoring it with the View export I'd created. It only worked if I told the view import interface to ignore errors or whatever and it just created all the Fields and filters and whatnot... all the associations were gone and when I tried to re-create them, they certainly didn't "connect" to the fields in the view.

I guess tomorrow is another day. :S

loopy1492’s picture

Title: New Field » Serious Schema Issues

I know have a lot of serious Schema issues stemming from the use of this module. I have several mismatches in the schema/database pertaining to the form I'm working with which are causing me problems.

  • e1_total_compensation: not in database
  • arp1_other_expenses: not in database
  • arp1_other_expenses_percentage: not in database
  • date_additional_information_requested: not in database
  • date_additional_information_received: not in database
  • original_information_received: unexpected column in database
  • original_information_requested: unexpected column in database
  • todaydate: unexpected column in database
  • date_nod_letter_sent: unexpected column in database

For example, somehow the "original_information_received" and "original_information_requested" fields do show up in the list of available fields to use in my views. Unfortunately, when I do include them, this error occurs:

SQLSTATE[42S22]: Column not found: 1054 Unknown column 'webform_submissions_webform_views_myform__webform_views_myform.date_additional_information_received' in 'field list'

I'm ASSUMING that the living field is "original_information_received" and "date_additional_information_received" is dead in the database, but the SCHEMA hasn't updated.

How the heck do I fix the Schema without re-installing it and destroying my view in the process?

Thanks!