Author Topic: Failed to import initial data. MySQL said: Column 'plugin_id' cannot be null  (Read 6524 times)

badincite

  • Newbie
  • *
  • Posts: 3
    • View Profile
Getting a (Failed to import initial data. MySQL said: Column 'plugin_id' cannot be null error) on step 4 everything else checks out fine.

FengOffice 3.1
Using MySQL 5.5 Community Edition - Supports InnoDB
PHP 5.6.6
Installed on IIS 7.5

badincite

  • Newbie
  • *
  • Posts: 3
    • View Profile
Anyone???

franponce87

  • Administrator
  • Hero Member
  • *****
  • Posts: 1819
    • View Profile
    • Email
Hi there!

Was this an installation or an upgrade?
Have you tried with the latest release?

Best,
Francisco
Would you like to install Feng Office Professional or Enterprise Edition in your servers? No problem! Read this article!

AdamEntity

  • Newbie
  • *
  • Posts: 1
    • View Profile
I am also having the same problem with the latest download of Feng 3.1.2.2

The first issue is related to the object_types requires that the plugin_id not be null.  As the plugin sqls begin to load data into the tables, a blank plugin_id is encountered and it crashes.  I altered the primary script under public/install/installation/templates/sql/mysql_schema.php  Line 145 to allow null values in plugin_id.

Reviewing the tables I notices that almost all entries have inserted records with null values except for three:
person, company, mail do have plugin ids.

Then lastly another error occurred:
Error while loading inital data for plugin 'workspaces'.Field 'path' doesn't have a default value


Regards,
AdamEntity

mark012492

  • Newbie
  • *
  • Posts: 5
    • View Profile
Same issue.

Failed to import initial data. MySQL said: Column 'plugin_id' cannot be null

Mysql 5.6
Feng 3.1.4.1

mark012492

  • Newbie
  • *
  • Posts: 5
    • View Profile
Must be an issue with MySQL 5.6 worked fine with MariaDB 10.0

mark012492

  • Newbie
  • *
  • Posts: 5
    • View Profile
Now the install completes but it just redirects to a whitepage. No errors in apache log.

Think I will look into alternatives.

mark012492

  • Newbie
  • *
  • Posts: 5
    • View Profile
After digging deeper.

MariaDB 10.0  works (likely works fine with mysql 5.5 havent tested)

php.ini included in source conflicts with suphp. Removed.

Switching to mysql from pdo_mysql resolved the max memory errors that prevented the menus from being displayed.

So far seems to be working.

mark012492

  • Newbie
  • *
  • Posts: 5
    • View Profile
Adding tasks results in

[05-May-2015 19:11:01 GMT] PHP Fatal error:  Call to a member function getParentId() on a non-object in /home/######/public_html/application/models/project_tasks/ProjectTask.class.php on line 1290

Foofah

  • Newbie
  • *
  • Posts: 3
    • View Profile
I have the same problem. :-/

MySQL Server version: 5.6.14
FO error: "Failed to import initial data. MySQL said: Column 'plugin_id' cannot be null"

Feng Office: 3.2.1

Anyone knows a solution for this?

Foofah

  • Newbie
  • *
  • Posts: 3
    • View Profile
So, I started digging into the scripts... Seems that the mysql_schema is not coherent with mysql_initial_data.

The Database is not set up properly.

The table object_types and permission_groups are created with plugin_id 'not NULL', while the initial_data tries to write NULL values.

Solution: edit mysql_initial_data.php and change all the plugin_id NULL values to '0' for tables object_types and permission_groups

hamid914

  • Newbie
  • *
  • Posts: 1
    • View Profile
So, I started digging into the scripts... Seems that the mysql_schema is not coherent with mysql_initial_data.

The Database is not set up properly.

The table object_types and permission_groups are created with plugin_id 'not NULL', while the initial_data tries to write NULL values.

Solution: edit mysql_initial_data.php and change all the plugin_id NULL values to '0' for tables object_types and permission_groups
Thank you Foofah!
I had the same problem and it is solved with your solution ;)