Help to understand drupal 7 database

I need help to understand the drupal 7 database. I want to build a module. There i want to use data from database. Can anybody explain me how a drupal 7 database is structured?

Codemaster's picture

Look into phpmyadmin

First, you should get some knowledge of MySQL and PHPMyAdmin. If you don't have this know how then it will be very timeconsuming to produce something of value in a normal time period. If you really want to develop a Drupal module then it is absolutely nesseccary to understand the basics. You need to understand PHP, MySQL, Drupal, and Drupal module development. There are good books about these fields out there. 

 

If you open phpmyadmin, then you will find the database for your Drupal installation. I will show you how it looks like:

 

phpmyadmin

 

At the right-hand site, you can click on the + symbol to list all available tables in your Drupal installation. As there are lots of tables, there is a navigation toolbar integrated at the left-hand side. I marked it in the screenshot for you. As the alternative, you can click directly at the database name. Then all available tables of your Drupal installation will be listed in the middle of the browser window. If you want to find something special you can use the browser search.

 

 

Every table has in most cases more than one column. You can identify each table entry with ids given there. In Drupal, nearly all information can be found by a unique id. The user table has as the example for each user a uid which is unique.  Here you can find a database structure plan of Drupal 6,7 and 8.

Vote the answer: 
0
No votes yet