download_count.install in Download Count 6        
                          
                  
                        
  
  
  
File
  download_count.install
  
    View source  
  <?php
function download_count_install() {
  
  drupal_install_schema('download_count');
}
function download_count_schema() {
  $schema['file_downloads'] = array(
    'fields' => array(
      'filename' => array(
        'type' => 'varchar',
        'length' => '255',
        'not null' => 1,
      ),
      'timestamp' => array(
        'type' => 'int',
        'not null' => 1,
        'default' => 0,
        'disp-width' => '11',
      ),
      'count' => array(
        'type' => 'int',
        'not null' => 1,
        'default' => 0,
        'disp-width' => '11',
      ),
    ),
    'unique keys' => array(
      'filename' => array(
        'filename',
      ),
    ),
  );
  return $schema;
}
function download_count_uninstall() {
  
  drupal_uninstall_schema('download_count');
}