Jump to content


Photo

Generate SQL script for table


  • Please log in to reply
2 replies to this topic

#1 bubberz

bubberz
  • New Members
  • Pip
  • Newbie
  • 1 posts

Posted 05 October 2005 - 02:46 PM

Is there a way to get the mySQL monitor to generate the SQL script for the creation of a table? I'm kinda looking for the same thing SQL Server does to allow you to preview the SQL script for a table.

Thanks!

#2 marker5a

marker5a
  • Members
  • PipPipPip
  • Advanced Member
  • 30 posts

Posted 05 October 2005 - 03:47 PM

If you have phpmyadmin or any mysql management software, usually there is a way to "dump" a database or a table. That will give you a printout of the actual SQL queries to make the database. Hope that helps

Chris

#3 ryanlwh

ryanlwh
  • Staff Alumni
  • Advanced Member
  • 511 posts

Posted 05 October 2005 - 04:45 PM

[!--sql--][div class=\'sqltop\']SQL[/div][div class=\'sqlmain\'][!--sql1--]SHOW CREATE TABLE tablename [!--sql2--][/div][!--sql3--]
Please use EDIT * 100...
Please use
or [php] * 1000...

PLEASE READ THE POSTED SOLUTIONS CAREFULLY * 1000000...




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users