Unable to delete a custom publication type. Generated error is:

Notice: Undefined variable: ftdids in biblio_admin_types_delete_form_submit() (line 1670 of /etc/drupal7/www.example.com/modules/biblio/includes/biblio.admin.inc).
•Warning: Invalid argument supplied for foreach() in DatabaseCondition->compile() (line 1853 of /usr/share/drupal7/includes/database/query.inc).
•PDOException: SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '))' at line 1: DELETE FROM {biblio_field_type_data} WHERE (ftdid IN ()) ; Array ( ) in biblio_admin_types_delete_form_submit() (line 1671 of /etc/drupal7/www.example.com/modules/biblio/includes/biblio.admin.inc).

MySQL version is 5.1.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

rupesh_jagtap’s picture

gmaxwelled’s picture

I can confirm that this patch fixes the issue.

joshuautley’s picture

Same here. Patch resolves the error.

joshuautley’s picture

Status: Needs review » Reviewed & tested by the community
rupesh_jagtap’s picture

Status: Reviewed & tested by the community » Patch (to be ported)

@rjerome - Can you please merge the shared patch?

Liam Morland’s picture

Status: Patch (to be ported) » Reviewed & tested by the community

Restoring status.

Liam Morland’s picture

Title: Error deleting custom publication type » Fix undefined index error in biblio_admin_types_delete_form_submit()
Version: 7.x-1.0-rc7 » 7.x-1.x-dev
Status: Reviewed & tested by the community » Fixed

Thanks!

Status: Fixed » Closed (fixed)

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