<br />
<b>Notice</b>:  Function _load_textdomain_just_in_time was called <strong>incorrectly</strong>. Translation loading for the <code>breadcrumb-navxt</code> domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the <code>init</code> action or later. Please see <a href="https://developer.wordpress.org/advanced-administration/debug/debug-wordpress/">Debugging in WordPress</a> for more information. (This message was added in version 6.7.0.) in <b>/home/devtools/public_html/blog/wp-includes/functions.php</b> on line <b>6131</b><br />
{"id":475,"date":"2012-08-06T18:53:00","date_gmt":"2012-08-06T21:53:00","guid":{"rendered":"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/"},"modified":"2021-09-04T18:10:57","modified_gmt":"2021-09-04T21:10:57","slug":"criando-uma-tabela-com-base-em-outra-ja-existente","status":"publish","type":"post","link":"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/","title":{"rendered":"Criando uma tabela com base em outra j\u00e1 existente"},"content":{"rendered":"<p>Come\u00e7o este post lhe questionando:<\/p>\n<p>De que forma eu posso duplicar uma tabela, estrutura e dados?<\/p>\n<p>Sei que devem haver v\u00e1rias formas e, hoje vou apresentar aos colegas duas, uma que copia estrutura e dados e outra somente a estrutura.<\/p>\n<p>O primeiro exemplo ser\u00e1 para uma cria\u00e7\u00e3o de uma nova tabela, duplicando a estrutura e dados.<\/p>\n<p>1\u00ba &#8211; Digamos que preciso duplicar minha tabela aniversariantes, que possui a seguinte estrutura:<\/p>\n<pre style=\"background-image: url('http:\/\/2.bp.blogspot.com\/_z5ltvMQPaa8\/SjJXr_U2YBI\/AAAAAAAAAAM\/46OqEP32CJ8\/s320\/codebg.gif'); background: #f0f0f0; border: 1px dashed #CCCCCC; color: black; font-family: arial; font-size: 12px; height: auto; line-height: 20px; overflow: auto; padding: 0px; text-align: left; width: 99%;\"><code style=\"color: black; word-wrap: normal;\">Show Create Table paposql.aniversariantes<\/code><code style=\"color: black; word-wrap: normal;\"> <\/code><\/pre>\n<pre style=\"background-image: url('http:\/\/2.bp.blogspot.com\/_z5ltvMQPaa8\/SjJXr_U2YBI\/AAAAAAAAAAM\/46OqEP32CJ8\/s320\/codebg.gif'); background: #f0f0f0; border: 1px dashed #CCCCCC; color: black; font-family: arial; font-size: 12px; height: auto; line-height: 20px; overflow: auto; padding: 0px; text-align: left; width: 99%;\"><code style=\"color: black; word-wrap: normal;\">\u00a0CREATE TABLE `aniversariantes` (  \n  `id_aniversariante` bigint(20) DEFAULT NULL,  \n  `nome` varchar(50) DEFAULT NULL,  \n  `dt_nascimento` date DEFAULT NULL,  \n  KEY `idx_dt_nascimento` (`dt_nascimento`)  \n ) ENGINE=InnoDB DEFAULT CHARSET=utf8  \n<\/code><\/pre>\n<p>2\u00ba &#8211; Na tabela, possu\u00edmos os dados:<\/p>\n<pre style=\"background-image: url('http:\/\/2.bp.blogspot.com\/_z5ltvMQPaa8\/SjJXr_U2YBI\/AAAAAAAAAAM\/46OqEP32CJ8\/s320\/codebg.gif'); background: #f0f0f0; border: 1px dashed #CCCCCC; color: black; font-family: arial; font-size: 12px; height: auto; line-height: 20px; overflow: auto; padding: 0px; text-align: left; width: 99%;\"><code style=\"color: black; word-wrap: normal;\">Select * From paposql.aniversariantes <\/code><\/pre>\n<pre style=\"background-image: url('http:\/\/2.bp.blogspot.com\/_z5ltvMQPaa8\/SjJXr_U2YBI\/AAAAAAAAAAM\/46OqEP32CJ8\/s320\/codebg.gif'); background: #f0f0f0; border: 1px dashed #CCCCCC; color: black; font-family: arial; font-size: 12px; height: auto; line-height: 20px; overflow: auto; padding: 0px; text-align: left; width: 99%;\"><code style=\"color: black; word-wrap: normal;\">\u00a01     Aniversariante 1     2012-01-01  \n 2     Aniversariante 2     2012-02-01  \n 3     Aniversariante 3     2012-03-01  \n 5     Aniversariante 5     2012-05-01  \n 6     Aniversariante 6     2012-06-01  \n 7     Aniversariante 7     2012-07-01  \n 8     Aniversariante 8     2012-08-01  \n 9     Aniversariante 9     2012-09-01  \n 10     Aniversariante 10     2012-10-01  \n 11     Aniversariante 11     2012-11-01  \n 12     Aniversariante 12     2012-12-01  \n<\/code><\/pre>\n<p>3\u00ba &#8211; Voltando ao in\u00edcio do post, como fazer duplicar esta tabela? Simples, vejamos:<\/p>\n<pre style=\"background-image: url('http:\/\/2.bp.blogspot.com\/_z5ltvMQPaa8\/SjJXr_U2YBI\/AAAAAAAAAAM\/46OqEP32CJ8\/s320\/codebg.gif'); background: #f0f0f0; border: 1px dashed #CCCCCC; color: black; font-family: arial; font-size: 12px; height: auto; line-height: 20px; overflow: auto; padding: 0px; text-align: left; width: 99%;\"><code style=\"color: black; word-wrap: normal;\"> Create Table paposql.aniversariantes_copia  \n Select * From paposql.aniversariantes  \n<\/code><\/pre>\n<p><a name=\"more\"><\/a><br \/>\n4\u00ba &#8211; Pronto, minha tabela aniversariantes foi duplicada com sucesso, vejamos a estrura:<\/p>\n<pre style=\"background-image: url('http:\/\/2.bp.blogspot.com\/_z5ltvMQPaa8\/SjJXr_U2YBI\/AAAAAAAAAAM\/46OqEP32CJ8\/s320\/codebg.gif'); background: #f0f0f0; border: 1px dashed #CCCCCC; color: black; font-family: arial; font-size: 12px; height: auto; line-height: 20px; overflow: auto; padding: 0px; text-align: left; width: 99%;\"><code style=\"color: black; word-wrap: normal;\"> CREATE TABLE `aniversariantes_copia` (  \n  `id_aniversariante` bigint(20) DEFAULT NULL,  \n  `nome` varchar(50) DEFAULT NULL  \n ) ENGINE=InnoDB DEFAULT CHARSET=utf8  \n<\/code><\/pre>\n<p>5\u00ba &#8211; Os dados:<\/p>\n<pre style=\"background-image: url('http:\/\/2.bp.blogspot.com\/_z5ltvMQPaa8\/SjJXr_U2YBI\/AAAAAAAAAAM\/46OqEP32CJ8\/s320\/codebg.gif'); background: #f0f0f0; border: 1px dashed #CCCCCC; color: black; font-family: arial; font-size: 12px; height: auto; line-height: 20px; overflow: auto; padding: 0px; text-align: left; width: 99%;\"><code style=\"color: black; word-wrap: normal;\">Select * From paposql.aniversariantes_copia <\/code><\/pre>\n<pre style=\"background-image: url('http:\/\/2.bp.blogspot.com\/_z5ltvMQPaa8\/SjJXr_U2YBI\/AAAAAAAAAAM\/46OqEP32CJ8\/s320\/codebg.gif'); background: #f0f0f0; border: 1px dashed #CCCCCC; color: black; font-family: arial; font-size: 12px; height: auto; line-height: 20px; overflow: auto; padding: 0px; text-align: left; width: 99%;\"><code style=\"color: black; word-wrap: normal;\">\u00a01     Aniversariante 1     2012-01-01  \n 2     Aniversariante 2     2012-02-01  \n 3     Aniversariante 3     2012-03-01  \n 5     Aniversariante 5     2012-05-01  \n 6     Aniversariante 6     2012-06-01  \n 7     Aniversariante 7     2012-07-01  \n 8     Aniversariante 8     2012-08-01  \n 9     Aniversariante 9     2012-09-01  \n 10     Aniversariante 10     2012-10-01  \n 11     Aniversariante 11     2012-11-01  \n 12     Aniversariante 12     2012-12-01  \n<\/code><\/pre>\n<p>Na instru\u00e7\u00e3o uso normalmente o comando Create Table, onde especifico que as colunas dever\u00e3o ser baseados na tabela aniversariantes j\u00e1 existe, mas, caso eu queria duplicar com apenas os campos id_aniversariante e nome eu tamb\u00e9m posso fazer a seguinte instru\u00e7\u00e3o:<\/p>\n<pre style=\"background-image: url('http:\/\/2.bp.blogspot.com\/_z5ltvMQPaa8\/SjJXr_U2YBI\/AAAAAAAAAAM\/46OqEP32CJ8\/s320\/codebg.gif'); background: #f0f0f0; border: 1px dashed #CCCCCC; color: black; font-family: arial; font-size: 12px; height: auto; line-height: 20px; overflow: auto; padding: 0px; text-align: left; width: 99%;\"><code style=\"color: black; word-wrap: normal;\"> Create Table paposql.aniversariantes_copia  \n Select id_aniversariante, nome From paposql.aniversariantes  \n<\/code><\/pre>\n<p>Feito, realizamos a duplica\u00e7\u00e3o da tabela de forma r\u00e1pida e f\u00e1cil, mas, voc\u00ea deve ter observado que tivemos um pequeno probleminha nesta opera\u00e7\u00e3o, certo?<\/p>\n<p>Quando criamos a tabela aniversariantes_copia podemos ver que o \u00edndice existente na tabela original n\u00e3o foi criado, para isto vamos agora aprender a utilizar a segunda forma de duplica\u00e7\u00e3o citada no in\u00edcio do post.<\/p>\n<p>6\u00ba &#8211; Novamente vamos ver a estrutura da tabela aniversariantes:<\/p>\n<pre style=\"background-image: url('http:\/\/2.bp.blogspot.com\/_z5ltvMQPaa8\/SjJXr_U2YBI\/AAAAAAAAAAM\/46OqEP32CJ8\/s320\/codebg.gif'); background: #f0f0f0; border: 1px dashed #CCCCCC; color: black; font-family: arial; font-size: 12px; height: auto; line-height: 20px; overflow: auto; padding: 0px; text-align: left; width: 99%;\"><code style=\"color: black; word-wrap: normal;\">Show Create Table paposql.aniversariantes_copia2 <\/code><code style=\"color: black; word-wrap: normal;\">\u00a0<\/code><\/pre>\n<pre style=\"background-image: url('http:\/\/2.bp.blogspot.com\/_z5ltvMQPaa8\/SjJXr_U2YBI\/AAAAAAAAAAM\/46OqEP32CJ8\/s320\/codebg.gif'); background: #f0f0f0; border: 1px dashed #CCCCCC; color: black; font-family: arial; font-size: 12px; height: auto; line-height: 20px; overflow: auto; padding: 0px; text-align: left; width: 99%;\"><code style=\"color: black; word-wrap: normal;\">\u00a0CREATE TABLE `aniversariantes` (  \n  `id_aniversariante` bigint(20) DEFAULT NULL,  \n  `nome` varchar(50) DEFAULT NULL,  \n  `dt_nascimento` date DEFAULT NULL,  \n  KEY `idx_dt_nascimento` (`dt_nascimento`)  \n ) ENGINE=InnoDB DEFAULT CHARSET=utf8  \n<\/code><\/pre>\n<p>7\u00ba &#8211; Agora vamos duplicar novamente a tabela s\u00f3 que desta vez somente a estrutura, e completa:<\/p>\n<pre style=\"background-image: url('http:\/\/2.bp.blogspot.com\/_z5ltvMQPaa8\/SjJXr_U2YBI\/AAAAAAAAAAM\/46OqEP32CJ8\/s320\/codebg.gif'); background: #f0f0f0; border: 1px dashed #CCCCCC; color: black; font-family: arial; font-size: 12px; height: auto; line-height: 20px; overflow: auto; padding: 0px; text-align: left; width: 99%;\"><code style=\"color: black; word-wrap: normal;\"> Create Table paposql.aniversariantes_copia2   \n    Like paposql.aniversariantes  \n<\/code><\/pre>\n<p>Feito, estrutura duplicada, vamos checar o resultado?<\/p>\n<pre style=\"background-image: url('http:\/\/2.bp.blogspot.com\/_z5ltvMQPaa8\/SjJXr_U2YBI\/AAAAAAAAAAM\/46OqEP32CJ8\/s320\/codebg.gif'); background: #f0f0f0; border: 1px dashed #CCCCCC; color: black; font-family: arial; font-size: 12px; height: auto; line-height: 20px; overflow: auto; padding: 0px; text-align: left; width: 99%;\"><code style=\"color: black; word-wrap: normal;\">Show Create Table paposql.aniversariantes_copia2 <\/code><\/pre>\n<pre style=\"background-image: url('http:\/\/2.bp.blogspot.com\/_z5ltvMQPaa8\/SjJXr_U2YBI\/AAAAAAAAAAM\/46OqEP32CJ8\/s320\/codebg.gif'); background: #f0f0f0; border: 1px dashed #CCCCCC; color: black; font-family: arial; font-size: 12px; height: auto; line-height: 20px; overflow: auto; padding: 0px; text-align: left; width: 99%;\"><code style=\"color: black; word-wrap: normal;\">\u00a0CREATE TABLE `aniversariantes_copia2` (  \n  `id_aniversariante` bigint(20) DEFAULT NULL,  \n  `nome` varchar(50) DEFAULT NULL,  \n  `dt_nascimento` date DEFAULT NULL,  \n  KEY `idx_dt_nascimento` (`dt_nascimento`)  \n ) ENGINE=InnoDB DEFAULT CHARSET=utf8  \n<\/code><\/pre>\n<p>Alerto aos colegas somente sobre a necessidade de renomear o \u00edndice, evitando assim a exist\u00eancia de um \u00edndice duplicado.<\/p>\n<p>Bom pessoal, espero que as dicas tenham sido mais uma vez \u00fateis e, sugest\u00f5es, cr\u00edticas ou elogios ser\u00e3o bem vindos.<\/p>\n<p>Grande abra\u00e7o.<i><\/i><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Come\u00e7o este post lhe questionando: De que forma eu posso duplicar uma tabela, estrutura e dados? Sei que devem haver v\u00e1rias formas e, hoje vou apresentar aos colegas duas, uma que copia estrutura e dados e outra somente a estrutura. O primeiro exemplo ser\u00e1 para uma cria\u00e7\u00e3o de uma nova tabela, duplicando a estrutura e &#8230; <a title=\"Criando uma tabela com base em outra j\u00e1 existente\" class=\"read-more\" href=\"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/\" aria-label=\"More on Criando uma tabela com base em outra j\u00e1 existente\">Ler mais<\/a><\/p>\n","protected":false},"author":1,"featured_media":849,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[272,49],"tags":[],"class_list":["post-475","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-banco-de-dados","category-mysql"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v24.9 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Criando uma tabela com base em outra j\u00e1 existente<\/title>\n<meta name=\"description\" content=\"Veja como \u00e9 poss\u00edvel criar uma nova tabela com base em uma j\u00e1 existente, sem a necessidade de criar tudo do zero.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/\" \/>\n<meta property=\"og:locale\" content=\"pt_BR\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Criando uma tabela com base em outra j\u00e1 existente\" \/>\n<meta property=\"og:description\" content=\"Veja como \u00e9 poss\u00edvel criar uma nova tabela com base em uma j\u00e1 existente, sem a necessidade de criar tudo do zero.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/\" \/>\n<meta property=\"og:site_name\" content=\"Devtools\" \/>\n<meta property=\"article:published_time\" content=\"2012-08-06T21:53:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2021-09-04T21:10:57+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/devtools.com.br\/blog\/wp-content\/uploads\/2013\/06\/MySQL-Logo.wine_.png\" \/>\n\t<meta property=\"og:image:width\" content=\"3000\" \/>\n\t<meta property=\"og:image:height\" content=\"2000\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Fabiano Abreu\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Escrito por\" \/>\n\t<meta name=\"twitter:data1\" content=\"Fabiano Abreu\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. tempo de leitura\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutos\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/\"},\"author\":{\"name\":\"Fabiano Abreu\",\"@id\":\"https:\/\/devtools.com.br\/blog\/#\/schema\/person\/aa3425fdfdefa404466fc49f6d122eed\"},\"headline\":\"Criando uma tabela com base em outra j\u00e1 existente\",\"datePublished\":\"2012-08-06T21:53:00+00:00\",\"dateModified\":\"2021-09-04T21:10:57+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/\"},\"wordCount\":306,\"commentCount\":2,\"publisher\":{\"@id\":\"https:\/\/devtools.com.br\/blog\/#\/schema\/person\/aa3425fdfdefa404466fc49f6d122eed\"},\"image\":{\"@id\":\"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/devtools.com.br\/blog\/wp-content\/uploads\/2013\/06\/MySQL-Logo.wine_.png\",\"articleSection\":[\"Banco de Dados\",\"MySQL\"],\"inLanguage\":\"pt-BR\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/\",\"url\":\"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/\",\"name\":\"Criando uma tabela com base em outra j\u00e1 existente\",\"isPartOf\":{\"@id\":\"https:\/\/devtools.com.br\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/devtools.com.br\/blog\/wp-content\/uploads\/2013\/06\/MySQL-Logo.wine_.png\",\"datePublished\":\"2012-08-06T21:53:00+00:00\",\"dateModified\":\"2021-09-04T21:10:57+00:00\",\"description\":\"Veja como \u00e9 poss\u00edvel criar uma nova tabela com base em uma j\u00e1 existente, sem a necessidade de criar tudo do zero.\",\"breadcrumb\":{\"@id\":\"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/#breadcrumb\"},\"inLanguage\":\"pt-BR\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"pt-BR\",\"@id\":\"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/#primaryimage\",\"url\":\"https:\/\/devtools.com.br\/blog\/wp-content\/uploads\/2013\/06\/MySQL-Logo.wine_.png\",\"contentUrl\":\"https:\/\/devtools.com.br\/blog\/wp-content\/uploads\/2013\/06\/MySQL-Logo.wine_.png\",\"width\":3000,\"height\":2000,\"caption\":\"MySQL\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"In\u00edcio\",\"item\":\"https:\/\/devtools.com.br\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Criando uma tabela com base em outra j\u00e1 existente\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/devtools.com.br\/blog\/#website\",\"url\":\"https:\/\/devtools.com.br\/blog\/\",\"name\":\"Devtools\",\"description\":\"Sua caixa de ferramentas online\",\"publisher\":{\"@id\":\"https:\/\/devtools.com.br\/blog\/#\/schema\/person\/aa3425fdfdefa404466fc49f6d122eed\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/devtools.com.br\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"pt-BR\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\/\/devtools.com.br\/blog\/#\/schema\/person\/aa3425fdfdefa404466fc49f6d122eed\",\"name\":\"Fabiano Abreu\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"pt-BR\",\"@id\":\"https:\/\/devtools.com.br\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/devtools.com.br\/blog\/wp-content\/uploads\/2022\/07\/Fabiano-Abreu.png\",\"contentUrl\":\"https:\/\/devtools.com.br\/blog\/wp-content\/uploads\/2022\/07\/Fabiano-Abreu.png\",\"width\":184,\"height\":184,\"caption\":\"Fabiano Abreu\"},\"logo\":{\"@id\":\"https:\/\/devtools.com.br\/blog\/#\/schema\/person\/image\/\"},\"sameAs\":[\"https:\/\/devtools.com.br\/blog\"],\"url\":\"https:\/\/devtools.com.br\/blog\/author\/admin\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Criando uma tabela com base em outra j\u00e1 existente","description":"Veja como \u00e9 poss\u00edvel criar uma nova tabela com base em uma j\u00e1 existente, sem a necessidade de criar tudo do zero.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/","og_locale":"pt_BR","og_type":"article","og_title":"Criando uma tabela com base em outra j\u00e1 existente","og_description":"Veja como \u00e9 poss\u00edvel criar uma nova tabela com base em uma j\u00e1 existente, sem a necessidade de criar tudo do zero.","og_url":"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/","og_site_name":"Devtools","article_published_time":"2012-08-06T21:53:00+00:00","article_modified_time":"2021-09-04T21:10:57+00:00","og_image":[{"width":3000,"height":2000,"url":"https:\/\/devtools.com.br\/blog\/wp-content\/uploads\/2013\/06\/MySQL-Logo.wine_.png","type":"image\/png"}],"author":"Fabiano Abreu","twitter_card":"summary_large_image","twitter_misc":{"Escrito por":"Fabiano Abreu","Est. tempo de leitura":"3 minutos"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/#article","isPartOf":{"@id":"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/"},"author":{"name":"Fabiano Abreu","@id":"https:\/\/devtools.com.br\/blog\/#\/schema\/person\/aa3425fdfdefa404466fc49f6d122eed"},"headline":"Criando uma tabela com base em outra j\u00e1 existente","datePublished":"2012-08-06T21:53:00+00:00","dateModified":"2021-09-04T21:10:57+00:00","mainEntityOfPage":{"@id":"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/"},"wordCount":306,"commentCount":2,"publisher":{"@id":"https:\/\/devtools.com.br\/blog\/#\/schema\/person\/aa3425fdfdefa404466fc49f6d122eed"},"image":{"@id":"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/#primaryimage"},"thumbnailUrl":"https:\/\/devtools.com.br\/blog\/wp-content\/uploads\/2013\/06\/MySQL-Logo.wine_.png","articleSection":["Banco de Dados","MySQL"],"inLanguage":"pt-BR","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/","url":"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/","name":"Criando uma tabela com base em outra j\u00e1 existente","isPartOf":{"@id":"https:\/\/devtools.com.br\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/#primaryimage"},"image":{"@id":"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/#primaryimage"},"thumbnailUrl":"https:\/\/devtools.com.br\/blog\/wp-content\/uploads\/2013\/06\/MySQL-Logo.wine_.png","datePublished":"2012-08-06T21:53:00+00:00","dateModified":"2021-09-04T21:10:57+00:00","description":"Veja como \u00e9 poss\u00edvel criar uma nova tabela com base em uma j\u00e1 existente, sem a necessidade de criar tudo do zero.","breadcrumb":{"@id":"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/#breadcrumb"},"inLanguage":"pt-BR","potentialAction":[{"@type":"ReadAction","target":["https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/"]}]},{"@type":"ImageObject","inLanguage":"pt-BR","@id":"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/#primaryimage","url":"https:\/\/devtools.com.br\/blog\/wp-content\/uploads\/2013\/06\/MySQL-Logo.wine_.png","contentUrl":"https:\/\/devtools.com.br\/blog\/wp-content\/uploads\/2013\/06\/MySQL-Logo.wine_.png","width":3000,"height":2000,"caption":"MySQL"},{"@type":"BreadcrumbList","@id":"https:\/\/devtools.com.br\/blog\/criando-uma-tabela-com-base-em-outra-ja-existente\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"In\u00edcio","item":"https:\/\/devtools.com.br\/blog\/"},{"@type":"ListItem","position":2,"name":"Criando uma tabela com base em outra j\u00e1 existente"}]},{"@type":"WebSite","@id":"https:\/\/devtools.com.br\/blog\/#website","url":"https:\/\/devtools.com.br\/blog\/","name":"Devtools","description":"Sua caixa de ferramentas online","publisher":{"@id":"https:\/\/devtools.com.br\/blog\/#\/schema\/person\/aa3425fdfdefa404466fc49f6d122eed"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/devtools.com.br\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"pt-BR"},{"@type":["Person","Organization"],"@id":"https:\/\/devtools.com.br\/blog\/#\/schema\/person\/aa3425fdfdefa404466fc49f6d122eed","name":"Fabiano Abreu","image":{"@type":"ImageObject","inLanguage":"pt-BR","@id":"https:\/\/devtools.com.br\/blog\/#\/schema\/person\/image\/","url":"https:\/\/devtools.com.br\/blog\/wp-content\/uploads\/2022\/07\/Fabiano-Abreu.png","contentUrl":"https:\/\/devtools.com.br\/blog\/wp-content\/uploads\/2022\/07\/Fabiano-Abreu.png","width":184,"height":184,"caption":"Fabiano Abreu"},"logo":{"@id":"https:\/\/devtools.com.br\/blog\/#\/schema\/person\/image\/"},"sameAs":["https:\/\/devtools.com.br\/blog"],"url":"https:\/\/devtools.com.br\/blog\/author\/admin\/"}]}},"_links":{"self":[{"href":"https:\/\/devtools.com.br\/blog\/wp-json\/wp\/v2\/posts\/475","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devtools.com.br\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devtools.com.br\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devtools.com.br\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/devtools.com.br\/blog\/wp-json\/wp\/v2\/comments?post=475"}],"version-history":[{"count":2,"href":"https:\/\/devtools.com.br\/blog\/wp-json\/wp\/v2\/posts\/475\/revisions"}],"predecessor-version":[{"id":1332,"href":"https:\/\/devtools.com.br\/blog\/wp-json\/wp\/v2\/posts\/475\/revisions\/1332"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devtools.com.br\/blog\/wp-json\/wp\/v2\/media\/849"}],"wp:attachment":[{"href":"https:\/\/devtools.com.br\/blog\/wp-json\/wp\/v2\/media?parent=475"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devtools.com.br\/blog\/wp-json\/wp\/v2\/categories?post=475"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devtools.com.br\/blog\/wp-json\/wp\/v2\/tags?post=475"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}