[Rt-commit] rt branch, 4.0/mysql-attribute-content-datatype, created. rt-4.0.5-60-ge249f67

Thomas Sibley trs at bestpractical.com
Mon Feb 13 22:56:15 EST 2012


The branch, 4.0/mysql-attribute-content-datatype has been created
        at  e249f67bb8fd860be693cbd540384823b8c5036c (commit)

- Log -----------------------------------------------------------------
commit e249f67bb8fd860be693cbd540384823b8c5036c
Author: Thomas Sibley <trs at bestpractical.com>
Date:   Mon Feb 13 22:30:31 2012 -0500

    Remove 64kb length limit on Attributes.Content under MySQL
    
    On Postgres, Oracle, and even SQLite, Attributes.Content is an
    ~unlimited length data type (TEXT, CLOB, LONGTEXT respectively).
    
    This fixes a bug when uploading large logos in the theme editor that
    caused the attribute to be truncated and no custom logo displayed.
    
    See [rt3 #19413].

diff --git a/etc/schema.mysql b/etc/schema.mysql
index c313aaf..9ed0337 100755
--- a/etc/schema.mysql
+++ b/etc/schema.mysql
@@ -413,7 +413,7 @@ CREATE TABLE Attributes (
   id INTEGER NOT NULL  AUTO_INCREMENT,
   Name varchar(255) NULL  ,
   Description varchar(255) NULL  ,
-  Content BLOB,
+  Content LONGBLOB,
   ContentType varchar(16) CHARACTER SET ascii,
   ObjectType varchar(64) CHARACTER SET ascii,
   ObjectId integer, # foreign key to anything
diff --git a/etc/upgrade/4.0.6/schema.mysql b/etc/upgrade/4.0.6/schema.mysql
new file mode 100644
index 0000000..ab32007
--- /dev/null
+++ b/etc/upgrade/4.0.6/schema.mysql
@@ -0,0 +1 @@
+ALTER TABLE Attributes MODIFY Content LONGBLOB;

-----------------------------------------------------------------------


More information about the Rt-commit mailing list