Query to delete database in MySQL
You would need special privileges to create or to delete a MySQL database. So, assuming you have access to the root user, you can create any database using the mysql mysqladmin binary.
Be careful while deleting any database because you will lose your all the data available in your database.
Here is an example to delete a database(TUTORIALS) created in the previous chapter −
[root@host]# mysqladmin -u root -p drop TUTORIALS Enter password:******
This will give you a warning and it will confirm if you really want to delete this database or not.
Dropping the database is potentially a very bad thing to do. Any data stored in the database will be destroyed. Do you really want to drop the 'TUTORIALS' database [y/N] y Database "TUTORIALS" dropped
Drop Database using PHP Script
PHP uses mysql_query function to create or delete a MySQL database. This function takes two parameters and returns TRUE on success or FALSE on failure.
bool mysql_query( sql, connection );
|sql||Required − SQL query to create or delete a MySQL database|
|connection||Optional − if not specified, then the last opened connection by mysql_connect will be used.|
Try the following example to delete a database −
WARNING − While deleting a database using the PHP script, it does not prompt you for any confirmation. So be careful while deleting a MySQL database.velana international airport cake international hermes international tracking international flights to india fedex international international call to uk track international package new international athens international airport international post tracking lego international space station canada international travel natwest international login wis international login sydney international tennis international bra size converter happy international womens day halewood international harley medic international ashford international truckstop lincoln international kingfisher international products international organizations redhead international test to release for international travel hotels belfast international airport international travel update uk international students zoetic international plc share price international business management 29 year old england rugby international politics and international relations belfast international airport hotel international airports pantheon international share price post office international shipping international meeting planner australia international borders hc marbella international hospital monzo international transfer rainbow room international avanti international resort trannel international clark international international post office tracking most international caps fifa international rankings clearwater international doha international airport international commerce centre bournemouth international centre events clarke international tremor international share chat beats international dub be good to me jones international rightmove international edinburgh international climbing arena hermes international shipping bls international international street food rt international department of international trade camborne science and international academy hsbc international transfer parcelforce international international womens day quotes finder international is there an international men's day wing international barbecue hot one impresses international composer phonics international international yoga day 2022 the international centre telford farnborough international caci international rosen inn international drive restaurant brand international mandmdirect returns international arris international share price scotland international fixtures murcia international airport international development jobs international nurses day light croda international international flags kotoka international airport doh hamad international international travel from uk vodafone international roaming international youth day usps international tracking sharon miss international uk belfast international airport car hire australia international students pcr test for international travel survival international international champions cup barbour international wax jacket witt international ladies tops international removals is there an international mens day cancun international airport international space station at night amnesty international israel apartheid aetna international cnn international news musicweb international streams of joy international drennan international transparency international corruption index international lamps international women's day 2022 memes international stones indira gandhi international airport international sim card international tyres international space station tonight international courier service allied international tesco international call app england rugby international arrested on suspicion of raping a teenager international bank international rugby today what does international mean quarantine rules in india for international travellers royal mail international tracked international day of peace nhs covid pass letter for international travel riverside international raceway cruelty free international drag race international all stars international days 2022 autumn international rugby fixtures international boyfriend day barbour international quilted jacket women's how long does it take to get an international driving permit tnt international tracking international courier international cricket council yara international nigel frank international euromonitor international lloyds international bank international centre for birds of prey toastmasters international voetbal international international day of happiness 2022 vwr international parking at belfast international airport international paint international marketing international maritime organization tesco international calling app cain international skipton international humane society international when will south africa allow international travel barbour international quilted jacket womens where is the international space station royal mail prices 2022 international lloyds international banking international hall luxury retreats international inc. england international international crisis group alkass international cup 2022 british international school stratford international to st pancras daytona international speedway international friendlies football live international bowls bowls: world championships 2022 murray international network international miss international 2022 uk babcock international group fedex international priority international football fixtures 2022 belfast international car parking international tractor arrivals belfast international barclays international student account zoetic international