function session_api_schema in Session API 7
Same name and namespace in other branches
- 6 session_api.install \session_api_schema()
Implements hook_schema().
File
- ./
session_api.install, line 11 - Install file for Session API.
Code
function session_api_schema() {
$schema['session_api'] = array(
'description' => 'Map Session API IDs to the {sessions} sid field.',
'fields' => array(
'sid' => array(
'type' => 'serial',
'not null' => TRUE,
),
'session_id' => array(
'type' => 'varchar',
'length' => 128,
'not null' => TRUE,
),
'timestamp' => array(
'type' => 'int',
'not null' => TRUE,
'default' => 0,
),
),
'primary key' => array(
'sid',
),
'unique keys' => array(
'session_id' => array(
'session_id',
),
),
'indexes' => array(
'timestamp' => array(
'timestamp',
),
),
);
return $schema;
}