Author:
Nils
Version:
2.0.5
Released:
7 February 2010
Category:
Field Types

Closed#4: Mediathek MySQL error

Hi I have a problem with Mediathek an Symphony 2.1.1:

I get this SQL-Error when I select an item of my own defined type “Publication” inside my type “Website-Article” using mediathek. I think it’s a problem with 2.1.1 because I didn’t have this problem before:

MySQL Error (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 ‘AND field_id = 83 LIMIT 1’ at line 4 in query “SELECT order FROM sym_fields_mediathek_sorting WHERE entry_id = AND field_id = 83 LIMIT 1”

Do you have any ideas?

If you want I can send to the the whole Ensemble-Export by email.

Thanks,

Andreas

PS: As you can see the entry_id is empty. I tested a lot and I think it occurs only with Mediathek instances which are restricted to my content type “publication” which again contains a Mediathek selection of “documents” which contain nothing more than a file upload field. Hope this helps.

PS: As you can see the entry_id is empty. I tested a lot and I think it occurs only with Mediathek instances which are restricted to my content type “publication” which again contains a Mediathek selection of “documents” which contain nothing more than a file upload field. Hope this helps.

Update: I found out that changing file “field.mediathek.php” at line 481ff the following way is a short-time workaround for the problem by removing the ordering:

before: // sort entries $order = $this->Parent->Parent->Database->fetchVar(‘order’, 0, “SELECT order FROM sym_fields_mediathek_sorting WHERE entry_id = ” . $wrapper->getAttribute(‘id’) . ” AND field_id = ” . $this->get(‘id’) . ” LIMIT 1” ); $sorted_ids = explode(‘,’, $order);

after: // sort entries // BUGFIX /$order = $this->Parent->Parent->Database->fetchVar(‘order’, 0, “SELECT order FROM sym_fields_mediathek_sorting WHERE entry_id = ” . $wrapper->getAttribute(‘id’) . ” AND field_id = ” . $this->get(‘id’) . ” LIMIT 1” );/ $sorted_ids = null;//explode(‘,’, $order);

Just for the records: Mediathek is not compatible with Symphony 2.1+. Please use Subsection Manager instead.

This issue is closed.

Symphony • Open Source XSLT CMS

Server Requirements

  • PHP 5.3-5.6 or 7.0-7.3
  • PHP's LibXML module, with the XSLT extension enabled (--with-xsl)
  • MySQL 5.5 or above
  • An Apache or Litespeed webserver
  • Apache's mod_rewrite module or equivalent

Compatible Hosts

Sign in

Login details