You are here

function webform_update_7419 in Webform 7.4

Add an index on submitted data.

File

./webform.install, line 2085
Webform module install/schema hooks.

Code

function webform_update_7419() {

  // Note: MS SQL Server does not support size-limited indexes and the column
  // type (text) is too big to fit inside index size limits.
  if (!db_index_exists('webform_submitted_data', 'data') && db_driver() != 'sqlsrv') {
    db_add_index('webform_submitted_data', 'data', array(
      array(
        'data',
        64,
      ),
    ));
  }
}