I am trying to follow edits made in a php file to patch a module and the instructions just say "In your database schema add this", which I could do if I knew where to find the file. When I look up drupal database schema it shows a map which doesn't help me to find the file. What do they mean exactly by in your database schema and how can I access this file in terminal? Is it by editing a table in the database?

I can find the other file alright to edit in /includes/database/mysql/schema.inc file but just not the specific module one.

The instructions for this vchess module patch are here

  • It might help if you mention the module, that you want to patch.
    – berliner
    Commented Mar 9, 2014 at 23:32

2 Answers 2


That particular instruction looks like it is suggesting you make the change in hook_schema() in the .install file.

To make the corresponding change in your own mysql database you would need to log into the mysql terminal and change the field "turns" in the 'vchess_games' table, adding the enum values of 'w' and 'b' to that ENUM field.

However it may be simpler to disable and uninstall the module, make the change to your vchess install file then re-enable the module. This decision should be based in how much data you already have in you vchess_games table though.

  • Thank you, my mistake I am not using version 8 but now I know how to find that file so I am going to give you the answer.
    – cea
    Commented Mar 10, 2014 at 2:56

Your database schema literally just means the structure of your database. It sounds like you're being instructed to manually make a change to this e.g. to add a column, which you could do in something like PHPmyadmin.

Normally a module's database schema is managed in its .install file. The initial schema is defined in hook_schema() and any changes are automated with hook_update_N(), but it sounds like you're being asked to make manual changes instead. Be careful!

  • Thanks, you are right but I still don't know where I make those changes because I use only terminal with no graphic interface such as phpadmin.Above is the link to the file to be changed.
    – cea
    Commented Mar 10, 2014 at 2:06
  • Actually no, they are giving instructions for changing files but I'm not sure this is what you think it is! This is a discussion on adding support for the ENUM datatype in Drupal 8 and is not about patching a specific module. The point about adding to your schema is an example of how it could be used.
    – gigabates
    Commented Mar 10, 2014 at 2:29
  • Yes, I was confused about the version because one headline read Drupal 7 finally stable but when I looked further into it I kept seeing version 8. That's a shame, I think it is a brilliant module. I will go with javascript backgammon instead. Thanks for clearing that up absolutely.
    – cea
    Commented Mar 10, 2014 at 2:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.