See Github for issue/resolution

I think I brought this up somewhere else, so apologies if I'm repeating myself - but the issue is more clear than it was before and quite a show stopper.

When I have both a date field and a file upload field on a section it cannot be saved. I keep getting the error:

Symphony Fatal Database Error: Column 'pre_populate' cannot be null

The field that's giving the error is the date field; but the date field on its own works fine, the error only triggers when I attempt to add a file upload field to a section.

Odd bug - and a critical one preventing me from moving forward on 2 projects. These are core extensions so hopefully there's a quick resolve??

Is this on a 2.4 build?

EDIT read the title! duh :/

:) Yup 2.4 master, haven't tested it on integration.

For reference the error in the Symphony logs is:

03/07/2014 14:47 > UNKNOWN: DatabaseException 0 - MySQL Error (1048): Column 'pre_populate' cannot be null in query: INSERT INTO sym_fields_date (pre_populate, field_id) VALUES (NULL, '35') on line 867 of /Users/Nathan/httpdocs/3degrees-agency/symphony/lib/toolkit/class.mysql.php

Incidentally that value shouldn't be null anyway, in this section it's set to the default now.

Looking at the POST information that field IS coming through as null though. Something in the upload field that's messing with the submission of the date field?

Can you file an issue on github Nathan?

I'm on 2.4 and have both upload and date field and don't see this issue. Is you install of setup with git? to pull changes in etc?

Also, is this a frontend form? or a backend section page? and does it happen with existing and new entries?

There may also need to be a little bit of fixing done here: due to the fact that it's checking for a value of yes... which I don't think is right.

I'm on 2.4 and have both upload and date field and don't see this issue.

Bugger, always makes it trickier.

This would have been, I think the basic 2.4 download from the downloads page. I only tend to use git for the submodules (or grabbing the integration branch, which I'm not using on this project).

This is in the backend. Pretty vanilla setup.

I'd be happy to pop the issue on Github, however I'm not 100% sure which field is causing the problem, or if it's Symphony itself. As it's the date field that has the issue, but only when the file upload field is present :) [Edit: Pointless distinction, as of course this is all part of the core!]

Important point:

I can successfully create a section with both of those fields.

What I can't do is add a file upload field, AFTER the section is created with a date field already in it. Not sure how you attempted to recreate it, so might be an important distinction.

I just tried and this seems consistent, at least on the site I'm working on at the mo.

An update, the zip file on this site contained the incorrect installation SQL file which lead to this error. It has now been fixed and the zip file corrected on here and on the Github repo.

Create an account or sign in to comment.

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