You are here

function matrix_field_schema in Matrix field 8.2

Same name and namespace in other branches
  1. 7.2 matrix.install \matrix_field_schema()

Implements hook_field_schema().

File

./matrix.install, line 12
Install, update and uninstall functions for the matrix module.

Code

function matrix_field_schema($field) {
  return array(
    'columns' => array(
      'row' => array(
        'type' => 'int',
        'not null' => FALSE,
      ),
      'col' => array(
        'type' => 'int',
        'not null' => FALSE,
      ),
      'value' => array(
        'type' => 'varchar',
        'length' => 255,
        'not null' => FALSE,
      ),
    ),
    'indexes' => array(
      'row' => array(
        'row',
      ),
      'col' => array(
        'col',
      ),
      'value' => array(
        'value',
      ),
    ),
  );
}