You are here

function forena_update_6202 in Forena Reports 6.2

Add language column

File

./forena.install, line 126
Installation api for module

Code

function forena_update_6202() {
  $ret = array();
  db_add_field($ret, 'forena_reports', 'language', array(
    'type' => 'varchar',
    'length' => 30,
    'not null' => TRUE,
    'default' => 'en',
  ));
  db_query("update {forena_reports} set language='en'");
  db_drop_primary_key($ret, 'forena_reports');
  db_add_primary_key($ret, 'forena_reports', array(
    'report_name',
    'language',
  ));
  return $ret;
}