Linux commands: Difference between revisions

Jump to navigation Jump to search
No change in size ,  1 November 2013
m
Line 99: Line 99:
{{exclaim}} Notice: existing database will be overwritten
{{exclaim}} Notice: existing database will be overwritten
* Import *.sql file:  
* Import *.sql file:  
*# (optional if the .sql file was compressed) {{kbd | key =unzip data.zip}} or {{kbd | key =gzip -v data.gz}} if the file was compressed by gzip
*# (optional if the .sql file was compressed) {{kbd | key =unzip data.zip}} or {{kbd | key =gzip -d data.gz}} if the file was compressed by gzip
*# {{kbd | key =  <nowiki>mysql -u username -p -h localhost DATA-BASE-NAME < data.sql</nowiki>}} <ref>[http://www.cyberciti.biz/faq/import-mysql-dumpfile-sql-datafile-into-my-database/ Import MySQL Dumpfile, SQL Datafile Into My Database]</ref> and press {{kbd | key =  <nowiki>Enter</nowiki> }}
*# {{kbd | key =  <nowiki>mysql -u username -p -h localhost DATA-BASE-NAME < data.sql</nowiki>}} <ref>[http://www.cyberciti.biz/faq/import-mysql-dumpfile-sql-datafile-into-my-database/ Import MySQL Dumpfile, SQL Datafile Into My Database]</ref> and press {{kbd | key =  <nowiki>Enter</nowiki> }}
*# enter {{kbd | key =  <nowiki>password</nowiki> }} and press {{kbd | key =  <nowiki>Enter</nowiki> }}
*# enter {{kbd | key =  <nowiki>password</nowiki> }} and press {{kbd | key =  <nowiki>Enter</nowiki> }}

Navigation menu