I'm working with the addressfield module. I need to change the thoroughfare column to have a max length of 960 (or make it a text instead of varchar) instead of the default 255.
However I'm not sure how I should do it.
I've created an empty module with a hook_schema_alter()
function hook_schema_alter(&$schema) {
$schema['addressfield']['thoroughfare'] = array(
'description' => 'The thoroughfare of this address. (i.e. Street address)',
'type' => 'text',
'default' => '',
'not null' => FALSE,
);
return $schema;
}
However I suspect that the part "$schema['addressfield']['thoroughfare']" is not correct. Nothing is changed when I install the module with this hook.
How to change it? In the original addressfield it returns only columns in the schema hook, it's not really linked to a schema itself?