{"id":270,"date":"2010-09-07T21:20:10","date_gmt":"2010-09-07T20:20:10","guid":{"rendered":"http:\/\/kb.toderu.ro\/?p=270"},"modified":"2010-09-07T21:20:10","modified_gmt":"2010-09-07T20:20:10","slug":"dump-just-the-table-structure-to-a-file-in-mysql","status":"publish","type":"post","link":"https:\/\/kb.toderu.ro\/?p=270","title":{"rendered":"Dump just the table structure to a file in MySQL"},"content":{"rendered":"<p>\t\t\t\tFor this exercise, we will use the mysqldump utility the same as if we were backing up the entire database.<\/p>\n<p>Syntax:    <\/p>\n<pre id=\"terminal\">mysqldump -d -h localhost -u root -pmypassword databasename > dumpfile.sql<\/pre>\n<p>The only option that is different than creating an entire backup is the -d switch, which tells mysqldump not to output the data.<\/p>\n<p>Example:    <\/p>\n<pre id=\"terminal\">mysqldump -d -h localhost -u root -p2Uad7as9 database01 > dumpfile.sql<\/pre>\n<p>source <a href=\"http:\/\/www.howtogeek.com\/howto\/programming\/mysql\/dump-just-the-table-structure-to-a-file-in-mysql\/\">http:\/\/www.howtogeek.com\/howto\/programming\/mysql\/dump-just-the-table-structure-to-a-file-in-mysql\/<\/a>\t\t<\/p>\n","protected":false},"excerpt":{"rendered":"<p>For this exercise, we will use the mysqldump utility the same as if we were backing up the entire database. Syntax: mysqldump -d -h localhost -u root -pmypassword databasename > dumpfile.sql The only option that is different than creating an entire backup is the -d switch, which tells mysqldump not to output the data. Example: [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5,7],"tags":[],"class_list":["post-270","post","type-post","status-publish","format-standard","hentry","category-linux","category-mysql"],"_links":{"self":[{"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=\/wp\/v2\/posts\/270","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=270"}],"version-history":[{"count":0,"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=\/wp\/v2\/posts\/270\/revisions"}],"wp:attachment":[{"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=270"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=270"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=270"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}