You are here

function top_searches_schema in Top Searches 7

Same name and namespace in other branches
  1. 6 top_searches.install \top_searches_schema()

File

./top_searches.install, line 27

Code

function top_searches_schema() {
  $schema['top_searches'] = array(
    'fields' => array(
      'qid' => array(
        'type' => 'serial',
        'length' => 11,
        'not null' => TRUE,
        'unsigned' => TRUE,
      ),
      'q' => array(
        'type' => 'varchar',
        'length' => 255,
        'not null' => TRUE,
        'default' => '',
      ),
      'counter' => array(
        'type' => 'int',
        'length' => 11,
        'not null' => FALSE,
        'default' => 0,
        'unsigned' => TRUE,
      ),
    ),
    'unique keys' => array(
      'q' => array(
        'q',
      ),
    ),
    'primary key' => array(
      'qid',
    ),
  );
  return $schema;
}