Created
August 2, 2011 15:51
-
-
Save johnrobertwilson/1120496 to your computer and use it in GitHub Desktop.
Getting wierd Incorrect Table definition when trying to install this skeleton module.. does anything look wrong?
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// $Id$ | |
/** | |
* Implementation of hook_schema() | |
* | |
* TODO: Describe the module's data model | |
* | |
*/ | |
function tcb_entities_schema() { | |
$schema = array(); | |
$schema['tcb_subject'] = array( | |
'description' => 'Subject', | |
'fields' => array( | |
'subject_id' => array( | |
'description' => '', | |
'type' => 'serial', | |
'not null' => TRUE, | |
), | |
'title' => array( | |
'description' => '', | |
'type' => 'char', | |
'length' => 200, | |
'not null' => TRUE, | |
), | |
), | |
'primary_key' => array('subject_id'), | |
); | |
return $schema; | |
} | |
/** | |
* Implementation of hook_install() | |
* | |
* Perform initial setup tasks | |
* | |
*/ | |
function tcb_entities_install() { | |
} | |
/** | |
* Implements hook_uninstall(). | |
*/ | |
function tcb_entities_uninstall() { | |
drupal_uninstall_schema('tcb_entities'); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment