Uploaded image for project: 'eZ Publish / Platform'
  1. eZ Publish / Platform
  2. EZP-16338

SQL schema for ezxmlexport extensions does not work anymore (in mysql)

    Details

      Description

      Hi

      When importing the .dba file for ezxmlexport in mysql I now get this error:

      [ Mar 04 2010 15:26:25 ] [] eZMySQLDB:
      Query error: 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 'NOT NULL DEFAULT '',
        PRIMARY KEY ( id )
      ) ENGINE=InnoDB' at line 5. Query: CREATE TABLE ezxmlexport_customers (
        ftp_target text NOT NULL,
        id int(11) NOT NULL AUTO_INCREMENT,
        name varchar(200) NOT NULL DEFAULT '',
        slicing_mode enum NOT NULL DEFAULT '',
        PRIMARY KEY ( id )
      ) ENGINE=InnoDB
      

      I guess this has is now broken, either because of changes to the schema, or regressions caused by other schema fixes.

      PS:
      Testing on both 4.3.0beta1, and on latest snapshot.

        Issue Links

          Activity

          Hide
          Gaetano Giunta added a comment -

          Also note that generating by hand the sql files should be discouraged (ie. desupporetd), esp. when such features are added that are not supported by .dba

          It is the .dba files that are read by the schema-fix page in the admin interface.

          btw, there is no usage of SMALLINT in oracle defs for any eZP table (other than this one).

          Show
          Gaetano Giunta added a comment - Also note that generating by hand the sql files should be discouraged (ie. desupporetd), esp. when such features are added that are not supported by .dba It is the .dba files that are read by the schema-fix page in the admin interface. btw, there is no usage of SMALLINT in oracle defs for any eZP table (other than this one).
          Hide
          Vidar Langseid added a comment -

          okay, after change all the schema stuff, it now works to import the schema using .dba file for all databases.

          However, tc-72 will still fail on oracle. When clicking "OK" button on /xmlexport/edit/(type)/export/(customer)1/ I get the following sql error (requires RedirectionDebug) :

          Error (1400): ORA-01400: kan ikke sette inn NULL i ("EZP"."EZXPORT_EXPORTS"."XSLT_FILE")
          Failed query at offset 405:
          INSERT INTO ezxport_exports (customer_id, name, description, sources, ftp_target, slicing_mode, start_date, end_date, export_schedule, export_limit, export_from_last, compression, related_object_handling, xslt_file, export_hidden_nodes) VALUES(1, 'tNews', 'Our news', 'a:1:{i:0;s:2:"59";}', 'a:0:{}', '1', 1268089200, 0, 'a:1:{s:8:"schedule";a:2:{s:5:"value";s:1:"1";s:4:"unit";s:3:"day";}}', 0, 0, 0, 1, '', 0)
           
          Start of error:
          '', 0)
          

          Show
          Vidar Langseid added a comment - okay, after change all the schema stuff, it now works to import the schema using .dba file for all databases. However, tc-72 will still fail on oracle. When clicking "OK" button on /xmlexport/edit/(type)/export/(customer)1/ I get the following sql error (requires RedirectionDebug) : Error (1400): ORA-01400: kan ikke sette inn NULL i ("EZP"."EZXPORT_EXPORTS"."XSLT_FILE") Failed query at offset 405: INSERT INTO ezxport_exports (customer_id, name, description, sources, ftp_target, slicing_mode, start_date, end_date, export_schedule, export_limit, export_from_last, compression, related_object_handling, xslt_file, export_hidden_nodes) VALUES(1, 'tNews', 'Our news', 'a:1:{i:0;s:2:"59";}', 'a:0:{}', '1', 1268089200, 0, 'a:1:{s:8:"schedule";a:2:{s:5:"value";s:1:"1";s:4:"unit";s:3:"day";}}', 0, 0, 0, 1, '', 0)   Start of error: '', 0)
          Hide
          Gaetano Giunta added a comment -

          In reply to comment #050945
          try
          . adding the attached dbschema.ini file in the extension settings dir
          . go to system upgrade page in admin, you should have some sql suggested now that asks you to alter the ezxport_exports table
          . run that sql on your db
          . unit test should pass

          Show
          Gaetano Giunta added a comment - In reply to comment #050945 try . adding the attached dbschema.ini file in the extension settings dir . go to system upgrade page in admin, you should have some sql suggested now that asks you to alter the ezxport_exports table . run that sql on your db . unit test should pass
          Hide
          Jérôme Renard added a comment -

          Hi Gaetano,

          I "nullified" the problematic field in the .dba file directly.

          Show
          Jérôme Renard added a comment - Hi Gaetano, I "nullified" the problematic field in the .dba file directly.
          Hide
          ezrobot added a comment -

          This issue has been automatically closed due to the lack of activity over a long period of time. It is very likely that it is obsolete, but if you think it is still valid, do not hesitate to reopen it and mention why.

          Show
          ezrobot added a comment - This issue has been automatically closed due to the lack of activity over a long period of time. It is very likely that it is obsolete, but if you think it is still valid, do not hesitate to reopen it and mention why.

            People

            • Assignee:
              Jérôme Renard
              Reporter:
              Vidar Langseid
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: