Error creating the list field

4 posts by 3 authors in: Forums > CMS Builder
Last Post: April 15, 2016   (RSS)

By Perchpole - April 12, 2016

Hello, All -

It's not often I find myself coming back here in search of answers to a question I first posted over a year ago - but needs must!

There is an error on a site which is generating the same error message several times a day:

E_USER_ERROR: There was an error creating the list field ''.
MySQL Error: Query was empty
$fieldSchema =
debug_backtrace: =

I discussed this issue with Dave some time ago but we both ended up scratching our heads. Clearly there is a problem creating a list somewhere but because there are no other details, I don't know how to further investigate the problem.

It's very frustrating. Could someone please give me some clues to what I should be looking for?

For example, what do the 2 single quotes (at the end of the first line of the error) indicate?

Secondly, why is the "Query:" line blank?

Thirdly, is the "Query empty" simply because no rows were returned or because there is an error in the query code?

I want to find this bug. I am happy to do the legwork - I just need to know what I am looking for!




By Damon - April 13, 2016

Hi Perch,

Are there any steps that I can take to recreate this error?

What version of CMS Builder are you using?

Can you post the link to the previous link with Dave so I can read up on the history? I searched for it but was unable to locate it.


Damon Edis -

Hire me! Save time by getting our experts to help with your project.

By Dave - April 15, 2016

Hi Perch, 

We added some error checking code to v3.00 and later for this in /lib/error_functions.php

  // detect servers with broken print_r (Seen July 2015 on 1&1 UK Shared Hosting Package occurs on HEAD request after any content sent, and causes our error logs to be blank!
  $brokenFunctions = array();
  ob_start(); echo '1'; $ob_get_clean_response = ob_get_clean();
  if (print_r(1, true) != '1')       { $brokenFunctions[] = "print_r"; }
  if ($ob_get_clean_response != '1') { $brokenFunctions[] = "ob_get_clean"; }
  if ($brokenFunctions) {
    $errorMessage = "WARNING: Server has broken PHP functions: " .implode(', ', $brokenFunctions). ". "
                  . "PHP software may not function correctly!  Please contact support for assistance.\n\n"
                  . "Original error: $errorMessage";

If you upgrade to the latest version of CMSB those should appear.  It's just some kind of glitch with your web host.  If it's not causing any problems you could try just ignoring it.

Hope that helps!

Dave Edis - Senior Developer