{"id":143,"date":"2011-03-10T17:51:32","date_gmt":"2011-03-10T17:51:32","guid":{"rendered":"http:\/\/shivdev.com\/blog\/?p=143"},"modified":"2011-03-10T17:51:32","modified_gmt":"2011-03-10T17:51:32","slug":"mysql-run-sql-queries-from-command-line","status":"publish","type":"post","link":"http:\/\/shivdev.com\/blog\/2011\/03\/10\/mysql-run-sql-queries-from-command-line\/","title":{"rendered":"MySQL: Run SQL Queries From Command Line"},"content":{"rendered":"<p>Here&#8217;s the syntax:<\/p>\n<blockquote><p>\nmysql -u user -p password database -e &#8216;SQL Query&#8217;\n<\/p><\/blockquote>\n<p>Here are a few examples:<\/p>\n<blockquote><p>\nmysql -u root -p mypass world -e &#8216;select * from city;&#8217;<br \/>\nmysql -u root -p mypass world -e &#8216;desc city;&#8217;\n<\/p><\/blockquote>\n","protected":false},"excerpt":{"rendered":"<p>Here&#8217;s the syntax: mysql -u user -p password database -e &#8216;SQL Query&#8217; Here are a few examples: mysql -u root -p mypass world -e &#8216;select * from city;&#8217; mysql -u root -p mypass world -e &#8216;desc city;&#8217;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[6],"tags":[],"_links":{"self":[{"href":"http:\/\/shivdev.com\/blog\/wp-json\/wp\/v2\/posts\/143"}],"collection":[{"href":"http:\/\/shivdev.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/shivdev.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/shivdev.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/shivdev.com\/blog\/wp-json\/wp\/v2\/comments?post=143"}],"version-history":[{"count":4,"href":"http:\/\/shivdev.com\/blog\/wp-json\/wp\/v2\/posts\/143\/revisions"}],"predecessor-version":[{"id":147,"href":"http:\/\/shivdev.com\/blog\/wp-json\/wp\/v2\/posts\/143\/revisions\/147"}],"wp:attachment":[{"href":"http:\/\/shivdev.com\/blog\/wp-json\/wp\/v2\/media?parent=143"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/shivdev.com\/blog\/wp-json\/wp\/v2\/categories?post=143"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/shivdev.com\/blog\/wp-json\/wp\/v2\/tags?post=143"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}