Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 2.5.0b5

Bug #5930 Using notnull causes error
Submitted: 2005-11-10 19:46 UTC
From: richtl at arscognita dot com Assigned: lsmith
Status: Closed Package: MDB2
PHP Version: 5.1.0 OS: Linux
Roadmaps: (Not assigned)    
Subscription  


 [2005-11-10 19:46 UTC] richtl at arscognita dot com
Description: ------------ Compiling a schema that has "notnull" tags results in "MDB2 Error: unknown error". It works fine if I remove the <notnull> tag. Environment is MDB2 2.0.0beta6 beta MDB2_Driver_mysql 0.1.1 beta MDB2_Driver_mysqli 0.1.1 alpha MDB2_Schema 0.2.0 beta Test script: --------------- <?xml version="1.0" ?> <database> <name>testdb</name> <create>1</create> <table> <name>table1</name> <declaration> <field> <name>field1</name> <type>integer</type> <notnull>1</notnull> </field> </declaration> </table> </database> Expected result: ---------------- Schema generated successfully, field is not nullable. Actual result: -------------- Schema generates error "MDB2 Error: unknown error" and doesn't compile.

Comments

 [2005-11-10 20:52 UTC] richtl at arscognita dot com
Working through it some more. setting <notnull>1</notnull> on my first field generates an error with the following (obviously broken) SQL: CREATE TABLE Thought (thoughtId INT DEFAULT NULL NOT NULL,summary CHAR (255) DEFAULT NULL,detail TEXT DEFAULT NULL,status CHAR (16) DEFAULT NULL,interacted DATETIME DEFAULT NULL)]
 [2005-11-12 16:02 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!