I have encountered some SQL errors when migrating Biblio from a Drupal 5 site to Drupal 6. Unescaped values were passed on to db_query().

CommentFileSizeAuthor
biblio-d6-update.patch1.88 KBDavid Lesieur

Comments

ohzbees’s picture

Is this related to the following fatal error I got when upgrading the MySQL database from Drupal 5 to 6:

An error occurred. http://$DOMAIN/update.php?id=8&op=do Fatal error: Unsupported operand types in /home/$USER/$DOMAIN/sites/all/modules/biblio/biblio.install on line 1673

David Lesieur’s picture

I don't remember the exact errors I had encountered, but since this is related to unescaped characters, I guess the errors could vary depending on your data.

You'll have the issue if you run Biblio's update #6000 and some Biblio field titles contain characters that have a special meaning in SQL (for example a single quote).

rjerome’s picture

Just for the record, this patch is in the latest code.

David Lesieur’s picture

I don't see it in DRUPAL-6--1 nor in the DRUPAL-6--2 branch. Am I missing something?

rjerome’s picture

Status: Needs review » Fixed

No, your not missing anything, I was :-)

It's done now...
http://drupal.org/cvs?commit=407676

Status: Fixed » Closed (fixed)

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

drupalina’s picture

Version: 6.x-1.13 » 6.x-1.x-dev
Status: Closed (fixed) » Active

I've just tried upgrading from Drupal 5.23 to 6.19 (from Biblio 5x-1.20 to Biblo 6x-1.14) and this Fatal error is popping up:

An error occurred. http://localhost/mywebsite523/update.php?id=5&op=do
Fatal error: Unsupported operand types in C:\wamp2\www\mywebsite523\sites\all\modules\biblio\biblio.install on line 1730

Then I have replaced my folder containing Biblio 6x-1.14 with the Biblio 6x-1x-dev (Aug 30 2010) and the problem persists.

Then I have replaced my folder containing Biblio 6x-1x-dev (Aug 30) with the Biblio 6x-2x-dev (Aug 30 2010) and the problem still persists !!!

I'm lost because I cannot effectively upgrade my site to Drupal6x now.

Note: just before running the upgrade when I unfold the update details it shown update #6015 and not #6000 by default. Should I choose #6000 ???

Would it be possible to commit a working patch to a stable release of Biblio 6x-1 or 6x-2 ?

Thanks for your help!

rjerome’s picture

Status: Active » Fixed

You ran into a different problem, which is fixed now. I've tested a 5 -6 upgrade a number of times and it works without issue now for me.

Ron.

http://drupal.org/cvs?commit=417112

drupalina’s picture

Status: Fixed » Active

Hi rjerome,
Sorry to reopen this. Before I saw your reply, what I did was replace the 2x-dev directory with 1x-dev (from Aug 30) and selected another upgrade number like #6027 (can't remember which exactly) instead of the default #6015. And the upgrade seems to have gone well. (no biblio related errors in the watchdog)
I wonder if this is what you meant by "You ran into a different problem" and I wonder if what I did was a good enough fix for me. I just need to know, because I'm working on the final (not test) upgrade version of the database, so that I know whether to import the 5x tables again and run the whole upgrade again with the latest 1x-dev release?

Thank you for your attention and great work!

rjerome’s picture

If you have a backup of your 5.x database, I would restore it and re-run the upgrade using one of the latest -dev versions dated Sept. 6 2010.

By selecting an upgrade point other than the default, you have skipped over a number of potentially important steps.

When I said you ran into a different problem, I meant that this issue was originally opened against an SQL error, but you are hitting an unrelated PHP syntax error.

Cheers,

Ron.

liam morland’s picture

Issue summary: View changes
Status: Active » Closed (outdated)

This version is no longer maintained. If this issue is still relevant to the Drupal 7 version, please re-open and provide details.