You are here

function prev_next_schema in Previous/Next API 7

Same name and namespace in other branches
  1. 8.2 prev_next.install \prev_next_schema()
  2. 6 prev_next.install \prev_next_schema()
  3. 7.2 prev_next.install \prev_next_schema()

@todo Please document this function.

See also

http://drupal.org/node/1354

File

./prev_next.install, line 37
The (un)install and update code for the prev_next module.

Code

function prev_next_schema() {
  $schema['prev_next_node'] = array(
    'description' => 'Prev/Next node',
    'fields' => array(
      'nid' => array(
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
      ),
      'prev_nid' => array(
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
      ),
      'next_nid' => array(
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
      ),
      'changed' => array(
        'type' => 'int',
        'unsigned' => TRUE,
        'not null' => TRUE,
      ),
    ),
    'primary key' => array(
      'nid',
    ),
    'indexes' => array(
      'prev_nid' => array(
        'prev_nid',
      ),
      'next_nid' => array(
        'next_nid',
      ),
    ),
  );
  return $schema;
}