Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Am using domain access module with tb_university theme. it has work well until resent when i try saving theme configuration for a domain I get "PDOException: SQLSTATE[22001]: String data, right truncated: 1406 Data too long for column 'settings' at row 1: " error
Comment | File | Size | Author |
---|---|---|---|
error msg.txt | 75.75 KB | allancache | |
error sreenshot.png | 80.61 KB | allancache |
Comments
Comment #2
allancache CreditAttribution: allancache commentedI have found out that data size of TB University theme settings is higher than size of other themes such as Batik, Bootstrap and Seven. The reason behind it is that TB University support "Page preview & direct settings" feature which allows you to regions and blocks settings. Therefore, the more blocks and more complex settings your site has will lead to bigger data size of the settings. According to your above error image, data size of TB University settings in your site somehow has been exceeded the maximum size of BLOB in MySQL which is 65535 bytes maximum. At the moment, I suggest you should manually modify type of "settings" column in domain_theme table in your database to a MEDIUMBLOB for 16777215 bytes or a LONGBLOB for 4294967295 bytes. So-that, the column could store more data.
Comment #3
agentrickardComment #4
paddy_deburca CreditAttribution: paddy_deburca as a volunteer commentedI have created a sub-theme of bootstrap (https://www.drupal.org/project/bootstrap 7.x-3.10), and when customising the domain theme I experienced the same issue.
Even if I do not change anything, and just edit the theme (admin/structure/domain/view/2/theme/subtheme/theme-settings) and click 'Save configuration', the error happens.
I have altered the
domain_theme
table, changing thesettings
column toMEDIUMBLOB
fromBLOB
- this solved my immediate problem. I will continue testing this sub-theme within the domain to see if there are any further side effects.ALTER TABLE `domain_theme` CHANGE `settings` `settings` MEDIUMBLOB NULL DEFAULT NULL ;