Posted by hswong3i on August 26, 2008 at 5:26pm
| Project: | Drupal core |
| Version: | 7.x-dev |
| Component: | database system |
| Category: | bug report |
| Priority: | critical |
| Assigned: | hswong3i |
| Status: | closed (won't fix) |
Issue Summary
By common programming logic, DB field with 'not null' => TRUE should always come with its default value, in order to prevent careless typing mistake or query implementation. But in case of MySQL, TEXT/BLOB don't support for default value (http://dev.mysql.com/doc/refman/5.1/en/blob.html):
BLOB and TEXT columns cannot have DEFAULT values.
According to our CVS HEAD implementation, we escape from this exceptional case within schema definition (bad). This patch try to catch the MySQL-specific requirement within its driver implementation (seems better), where keep the overall schema definition as simple as possible.
| Attachment | Size | Status | Test result | Operations |
|---|---|---|---|---|
| mysql-schema-default.patch | 908 bytes | Ignored: Check issue status. | None | None |
Comments
#1
Patch reroll via CVS HEAD.
#2
#3
@hswong3i: I think this is a "won't fix" based on the fact that you're adding what others call baby sitting code. The originator of the schema should fix his code so it should just fail.