You can also use TRUNCATE TABLE table_name;
this recreates the table, instead if just removing all data from it. To get to know more about the table structure, you may want to use: SHOW CREATE TABLE table_name; It shows you the create table statement of the table. -----Oorspronkelijk bericht----- Van: Adam Williams [mailto:[EMAIL PROTECTED]] Verzonden: 28 August 2002 03:19 Aan: Trevor Tregoweth CC: mysql; PHP Onderwerp: Re: [PHP] Re: Command Line if you just wanna delete everything from the tables you can do DELETE FROM table_name; for each table. or you can do DROP table_name; for each one but then you have to re-create each table that you drop with CREATe TABLE ( stuff here ); Only use DROP table_name; if you know the structure of each table. If you need the table names do SHOW TABLES; and if you need their structure use DESCRIBE table_name; Adam On Wed, 28 Aug 2002, Trevor Tregoweth wrote: > Hi > > I am very new to mysql, so any help please.... > > how to drop tables from a database from the command line > > i have 6 tables in there, and need to be able to flush all the data out, (of > 2 tables only) so there might be another way > > Thanks > > Trevor > > > --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php