I'm playing with customizing my own little module in Drupal, but I can't find any documentation for database fields. For example, in the "comments" table, where can I find definitions for the following fields?

pid int(10) NOT NULL default '0',
status tinyint(3) unsigned NOT NULL default '0',
format int(4) NOT NULL default '0',
users longtext,
name varchar(60) default NULL,
mail varchar(64) default NULL,
homepage varchar(255) default NULL

Thanks
Ben Slade
PublicMailbox at benslade dot.com (append 030516 to the subj to bypass spam filters)
Reality is merely an illusion, albeit a very persistent one. Albert Einstein

Comments

Chris Johnson’s picture

Do you mean the SQL statements that define the tables and columns? They are all in the database/ directory of the install.

Or did you mean something else?

bslade’s picture

The SQL statements only define the format of the columns. They don't tell you what the values of numerically coded fields mean.

In the above example, what does a value of 1 mean for the status field? It's good to be documented so that everybody uses it in the same way.

PublicMailbox@benslade.com
(append 030516 to the subj to bypass spam filters)
"It's the mark of an educated mind to be moved by statistics"
Oscar Wilde

chx’s picture

come, there is gold to be found! in this age, information is the greatest value. and what you ask for is buried well within the drupal code and in the developer's heads. come, join the drupal-docs team, free this knowledge, meet interesting people, like Boris Mann!

--
Drupal development: making the world better, one patch at a time. | A bedroom without a teddy is like a face without a smile.

bslade’s picture

What specifically does "join the drupal-docs team" mean? I'm already on the mailing list. Does it mean getting special permission to update/create documentation files? Are "they" sure they want to give me permission to edit things?

PublicMailbox@benslade.com
(append 030516 to the subj to bypass spam filters)
"It's the mark of an educated mind to be moved by statistics"
Oscar Wilde

chx’s picture

only the mailing list. What I meant: find the information in Drupal code, write it to the mailing list and there will be people who will happily add it to the handbook. If you begin to document the SQL tables of Drupal, then it will be "build it and they will come" -- I myself will join the doc list just to be able to add that info to the handbook.

--
Drupal development: making the world better, one patch at a time. | A bedroom without a teddy is like a face without a smile.