Como restaurar um arquivo .SQL no banco MySQL com Mysql Workbench

Caso não tenha o programa em sua estação o mesmo está disponível em http://dev.mysql.com/downloads/workbench/ .

Para realizar o backup da base abra o Mysql Workbench , e clique na opção “New Server Instance” .
Como restaurar um arquivo .SQL no banco MySQL com Mysql Workbench

Marque a opção “Remote Host”, e inclua o endereço de acesso a base ou o ip do servidor e clique em Next .
Como restaurar um arquivo .SQL no banco MySQL com Mysql Workbench
Nesta tela será pedido os detalhes da conexão com o banco de dados :

  • Connection Method : Standard (TCP/IP)
  • Hostname : Endereço de acesso ao banco, ou o ip do Servidor
  • Username : Usuário de acesso ao banco
  • Default Schema : Inclua o nome da base de dados

Após Preencher com os dados de conexão com a base de dados, clique em Next , e será pedido a senha de acesso ao banco de dados .

Como restaurar um arquivo .SQL no banco MySQL com Mysql Workbench

Como restaurar um arquivo .SQL no banco MySQL com Mysql Workbench

Após Incluir a senha da base e clicar em ok, o programa irá se conectar a base de dados, clique em Next neste passo .

Na Tela Seguinte marque a opção “Do not Use Remote Management” e clique em Next .
Como restaurar um arquivo .SQL no banco MySQL com Mysql Workbench
Depois será pedido o nome desejado a conexão novamente, de o nome que desejar e clique em Finish .

Restore do Arquivo.SQL

Com a conexão da base de dados já configurada, clique em “Manage Import / Export” , selecione sua base de dados e clique em OK .
Como restaurar um arquivo .SQL no banco MySQL com Mysql Workbench

Na Aba “Import from Disk” , marque a opção “Import From Self-Contained File” .
Como restaurar um arquivo .SQL no banco MySQL com Mysql Workbench

Clique no botão … e selecione o arquivo .sql em sua estação e clique em “Start Import” para iniciar o restore .

Importando em um novo banco de dados

Caso esteja importando o arquivo ‘.SQL’ em um novo banco de dados poderá receber o erro abaixo:

Como restaurar um arquivo .SQL no banco MySQL com Mysql Workbench

Para resolver este problema você precisará alterar o nome da base nas instruções Create Database, USE e Definer editando o arquivo ‘.SQL’ com um editor de texto conforme abaixo:

Como restaurar um arquivo .SQL no banco MySQL com Mysql Workbench

Apenas utilize a opção ‘Replace ALL'(Substituir todos) se tiver certeza de que o nome da base não faz parte do conteúdo de seus dados, caso não tenha certeza altere um a um:

Como restaurar um arquivo .SQL no banco MySQL com Mysql Workbench

Depois de alterar e salvar o arquivo ‘.SQL’ importe novamente e receberá uma mensagem conforme figura abaixo:

Como restaurar um arquivo .SQL no banco MySQL com Mysql Workbench

Veja também


Esse artigo ajudou você?

45 respostas para “Como restaurar um arquivo .SQL no banco MySQL com Mysql Workbench”

  1. Strawberry Cough Feminized Cannabis Seeds

    Right here is the perfect blog for everyone who wishes to understand this topic. You understand a whole lot its almost hard to argue with you (not that I personally will need to…HaHa). You definitely put a new spin on a topic that has been discussed for decades. Excellent stuff, just excellent.

    Responder
  2. sexy strappy lingerie

    Great tremendous things here. I¡¦m very satisfied to peer your article. Thanks a lot and i am looking forward to contact you. Will you please drop me a mail?

    Responder
  3. Joel Esch

    Having read this I believed it was extremely informative. I appreciate you taking the time and energy to put poker online terpercaya this article together. I once again find myself spending a significant amount of time both reading and leaving comments

    Responder
  4. free horror

    Aw, this was a very good post. Taking the time and actual effort to produce a top notch article… but what can I say… I hesitate a whole lot and don’t seem to get nearly anything done.

    Responder
  5. Affiliate Marketing Training

    Fantastic blog post! I’ll be back to view your next piece! Thank you!

    Responder
  6. Noble Britain

    Wow! This could be one of the most useful blogs we have ever come across on thesubject. Actually excellent info! I’m also an expert in this topic so I can understand your effort.

    Responder
  7. check my reference legal news central

    It’s onerous to find educated folks on this matter, however you sound like you realize what you’re speaking about! Thanks

    Responder
  8. Dionne Banks

    Excellent blog here! after reading, i decide to buy a sleeping bag ASAP

    Responder
  9. Pest Control Mike

    If you are looking for the best pest control company, look no more. These guys are awesome!

    Responder
  10. Pretty Gaming

    I like it when people come together and share opinions. Great site, continue the good work.

    Responder
  11. Harry Dececco

    Thanks for the post, was an interesting read. Curious as to how you came about that solution…

    Responder
  12. Cary Sprinkel

    Thx so much !!! Appreciate the useful info. I love sucking dick btw hmu

    Responder
  13. White glove service

    Thanks, I’ve recently been searching for info approximately this topic for ages and yours is the greatest I have came upon till now. But, what about the conclusion? Are you sure concerning the source?

    Responder
  14. Kristopher Dimascio

    Remarkable post and will look forward to your future update. Be sure to keep writing more great articles like this one.

    Responder
  15. Cure For Hip Dysplasia In Dogs

    Hmm it looks like your website ate my first comment (it was super long) so I guess I’ll just sum it up what I submitted and say, I’m thoroughly enjoying your blog. I too am an aspiring blog writer but I’m still new to the whole thing. Do you have any recommendations for first-time blog writers? I’d certainly appreciate it.

    Responder
  16. Laila Locastro

    My spouse and i have been fortunate that John managed to complete his investigation out of the precious recommendations he came across using your blog. It is now and again perplexing just to possibly be giving for free concepts which usually a number of people may have been selling. So we figure out we now have the blog owner to thank because of that. The main explanations you have made, the straightforward web site menu, the friendships your site help to engender – it’s mostly overwhelming, and it is assisting our son and our family know that the matter is exciting, which is incredibly indispensable. Thanks for the whole thing!

    Responder
  17. 슬롯 머신

    Best view i have ever seen !

    Responder
  18. Cure For Gout In Foot

    Hello.This article was extremely interesting, especially since I was browsing for thoughts on this topic last week.

    Responder
  19. 스포츠 북

    Best view i have ever seen !

    Responder
  20. about his

    I just want to say I am just beginner to blogging and truly savored this blog. Almost certainly I’m planning to bookmark your website . You absolutely come with awesome posts. Kudos for revealing your web-site.

    Responder
  21. Crankbrothers Mountain Bike Pedals for sale

    Yet another thing I would like to convey is that instead of trying to suit all your online degree classes on days and nights that you finish work (as most people are fatigued when they return home), try to have most of your instructional classes on the week-ends and only 1 or 2 courses in weekdays, even if it means taking some time away from your weekend. This is beneficial because on the weekends, you will be extra rested and concentrated in school work. Thanks a lot for the different recommendations I have figured out from your blog.

    Responder
  22. local plumbers Visit Your URL

    I loved up to you’ll receive performed right here. The comic strip is attractive, your authored material stylish. nevertheless, you command get bought an impatience over that you would like be handing over the following. unwell definitely come more previously again since precisely the similar nearly very incessantly inside case you protect this increase.

    Responder
  23. 출장마사지

    An outstanding share! I’ve just forwarded this onto a coworker who had been doing a little research on this. And he in fact ordered me breakfast due to the fact that I found it for him… lol. So let me reword this…. Thank YOU for the meal!! But yeah, thanx for spending the time to talk about this issue here on your blog.

    Responder
  24. foundation repair logo

    Hello there! I know this is kinda off topic but I was wondering if you knew where I could get a captcha plugin for my comment form? I’m using the same blog platform as yours and I’m having problems finding one? Thanks a lot!

    Responder
  25. 마사지구인구직

    Incredible. Guru. You’re the professional. Give thanks you.

    Responder
  26. 슬롯 게임

    Best view i have ever seen !

    Responder
  27. VitalFlow reviews

    Can I just say what a relief to find somebody who truly knows what they are discussing online. You definitely realize how to bring an issue to light and make it important. More people must read this and understand this side of your story. I can’t believe you’re not more popular since you surely have the gift.

    Responder
  28. home Warranty america

    Nice blog here! Also your web site a lot up very fast!
    I desire my site loaded up as quickly as yours…

    Responder
  29. 24 hour plumber near me why not look here

    Hey there would you mind letting me know which hosting company you’re using? I’ve loaded your blog in 3 different internet browsers and I must say this blog loads a lot quicker then most. Can you suggest a good internet hosting provider at a reasonable price? Cheers, I appreciate it!

    Responder
  30. Swing set installers

    Wow, awesome blog layout! How long have you been blogging for? you make blogging look easy. The overall look of your website is great, as well as the content!

    Responder
  31. home renovation themes

    Thanks for the auspicious writeup. It in fact was once a leisure account it. Look complicated to more delivered agreeable from you! However, how could we keep up a correspondence?

    Responder
  32. Bariatric Choice Multivitamin

    Thanks a bunch for sharing this with all of us you actually realize what you’re speaking approximately! Bookmarked. Kindly also seek advice from my web site =). We will have a link exchange arrangement between us!

    Responder
  33. Pool table movers

    Thank you, I have recently been searching for info about this topic for a while and yours is the best I’ve found out so far. But, what in regards to the bottom line? Are you sure in regards to the source?

    Responder
  34. White glove delivery

    Hey There. I found your blog using msn. This is a really well written article. I will make sure to bookmark it and return to read more of your useful information. Thanks for the post. I will definitely return.

    Responder
  35. digital marketing 360 mysore

    Undeniably imagine that which you said. Your favourite justification seemed to be on the internet the simplest thing to remember of. I say to you, I certainly get annoyed at the same time as people think about worries that they plainly don’t recognise about. You controlled to hit the nail upon the top as well as outlined out the entire thing without having side effect , other people could take a signal. Will likely be again to get more. Thanks

    Responder
  36. see it here

    I just want to mention I am beginner to blogging and really savored this page. Almost certainly I’m likely to bookmark your blog post . You amazingly come with outstanding writings. Thanks a lot for sharing your web-site.

    Responder
  37. advice

    Enjoyed reading this, very good stuff, regards . “Success doesn’t come to you…you go to it.” by Marva Collins.

    Responder
  38. roadside assistance

    Thankyou for helping out, wonderful information.

    Responder
  39. alberta car towing

    Its such as you learn my mind! You seem to grasp a lot about this, such as you wrote the ebook in it or something. I think that you simply could do with a few p.c. to power the message house a little bit, however other than that, this is fantastic blog. An excellent read. I will definitely be back.

    Responder
  40. Commercial cleaning company

    Thanks for any other informative web site. The place else may just I am getting that kind of information written in such a perfect method? I’ve a venture that I’m simply now running on, and I’ve been at the glance out for such info.

    Responder
  41. browse around this web-site

    Good – I should certainly pronounce, impressed with your web site. I had no trouble navigating through all tabs as well as related info ended up being truly easy to do to access. I recently found what I hoped for before you know it in the least. Reasonably unusual. Is likely to appreciate it for those who add forums or anything, website theme . a tones way for your customer to communicate. Nice task..

    Responder
  42. this link

    I will immediately grasp your rss as I can’t to find your email subscription link or newsletter service. Do you’ve any? Please permit me know in order that I could subscribe. Thanks.

    Responder
  43. Theresia Goldsboro

    I just want to say I am just new to weblog and truly loved this web page. Most likely I’m going to bookmark your blog post . You actually have excellent writings. Thank you for sharing with us your web site.

    Responder

Comente sobre este conteúdo! Escreva o que pensa, complemente, vamos discutir. O conhecimento é livre!