Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


How to drop the table using module?



How to drop the table using module?..

Answer / Lavesh Agarwal

To drop a table using a Drupal 7 module, you can create an .install file for your custom module and use the schema API to drop the table. Here's an example:n1. Create or edit the .install file.n2. Define a hook_schema() implementation in the file.n3. In the hook_schema(), define the table info array and set the 'sequence' key to TRUE for each field to ensure that the table is dropped before any data in it is deleted.n4. Use db_drop_table() function to drop the table.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Drupal Interview Questions

What is wordpress drupal?

1 Answers  


What are system requirements for drupal?

1 Answers  


How will you install new theme in drupal?

1 Answers  


What is drush cr?

1 Answers  


What is Drupal blocks?

1 Answers  


Do you keep regular backups?

1 Answers  


What is cron in drupal ?

1 Answers  


What is caching layer?

1 Answers  


Any patch contributed to drupal community?

1 Answers  


List the seo modules available in drupal?

1 Answers  


explain drupal advanced search?

1 Answers  


How to move a drupal site from one host/server to another on your new host?

1 Answers  


Categories