1046 no database selected joomla hosting
Je suis un programmeur Montréalais à Berlin. J'ai travaillé pour Nokia et IBM, et j'ai aidé plusieurs petites entreprises à voir grand sur le web.
Fixing the " #1046: No database selected " error
Here is the simple, quick fix to the "#1046: No database selected" error when importing a .sql file from a Wamp installation in phpMyAdmin.
In phpMyAdmin, click the Export tab situated under Home instead of the one when you are viewing the database to export. This will allow you to export entire databases and not only the tables contained in it. This might not work for users of hosting sites such as Hostmonster or Hostgator, since they pick the database names for you.
Alternative fix:
- Create the database on your server and note down the name.
- Open your .sql file with a text editor. You might want to use something other than Notepad since it doesn't recognize the line breaks.
- Insert the following line before your first CREATE TABLE command in your .sql file:
Gareth a dit (8 juin. 2010):
Thanks, this error was really bugging me!
willyzl a dit (28 oct. 2011):
Very Good solution. It is what I try looking for days. Thank you for your cool solutions. DD
Austin a dit (1 nov. 2011):
you are a godsend, sir.
LJ a dit (7 jan. 2012):
I still cant do it. After i followed the steps I get and erro 1044. Could you post a video on how to do it? That would be really helpful.
My whole website is ready and this is the final step and I am stuck here. I am not a web developer infact and not sure how to resolve it.
Dennis Guerra a dit (17 jan. 2012):
Thank you so much.
Was desperate
Shruti a dit (12 fév. 2012):
Wow! Works like a charm!
I got 1050 error after that. So deleted the existing tables in that database..
Thanks a lot!
Grazzer a dit (19 fév. 2012):
Was struggling to do this. Used your instructions. All done and dusted. Many thanks …
Simen a dit (12 mar. 2012):