{"id":842,"date":"2019-03-12T14:04:49","date_gmt":"2019-03-12T18:04:49","guid":{"rendered":"https:\/\/folvera.commons.gc.cuny.edu\/?p=842"},"modified":"2021-09-16T14:57:29","modified_gmt":"2021-09-16T18:57:29","slug":"installing-sql-server-express-in-macos","status":"publish","type":"post","link":"https:\/\/folvera.commons.gc.cuny.edu\/?p=842","title":{"rendered":"Installing SQL Server Express in macOS"},"content":{"rendered":"<p><strong>Instructions:<\/strong><\/p>\n<ol>\n<li>Open <tt>`Terminal`<\/tt>.\n<pre>Application\/Utilities\/Terminal.app<\/pre>\n<\/li>\n<li>Install the Homebrew package manager system.\n<pre>\/usr\/bin\/ruby -e \"$(curl -fsSL https:\/\/raw.githubusercontent.com\/Homebrew\/install\/master\/install)\"<\/pre>\n<\/li>\n<li>Test Homebrew installation.\n<pre>brew doctor<\/pre>\n<\/li>\n<li>Install Docker using Homebrew.\n<pre>brew install docker<\/pre>\n<\/li>\n<li>Run Docker and download the latest package of SQL Server.\n<pre>sudo docker pull mcr.microsoft.com\/mssql\/server:2017-latest<\/pre>\n<\/li>\n<li>Accept the EULA (End-User Licensing Agreement) and enter a <tt>`sa`<\/tt> (system administrator) password (position shown below as <tt>`&lt;YourStrong!Passw0rd&gt;`<\/tt>). This is the account that will run SQL Server using port 1433 to access container <tt>`sql1`<\/tt>.\n<pre>sudo docker run -e 'ACCEPT_EULA=Y' -e 'SA_PASSWORD=&lt;YourStrong!Passw0rd&gt;' \\\r\n  -p 1433:1433 --name sql1 \\\r\n  -d mcr.microsoft.com\/mssql\/server:2017-latest<\/pre>\n<\/li>\n<li>View all containers created. You should see container `sql1`.\n<pre>sudo docker ps -a<\/pre>\n<\/li>\n<li>Connect to SQL Server in container `sql1`.\n<pre>sudo docker exec -it sql1 \"bash\"<\/pre>\n<\/li>\n<li>Connect to `sqlcmd` (SQL Command).\n<pre>\/opt\/mssql-tools\/bin\/sqlcmd -S localhost -U SA -P '&lt;YourNewStrong!Passw0rd&gt;'<\/pre>\n<\/li>\n<li>At this point, you can stop the execution of `sqlcmd`.\n<pre>QUIT<\/pre>\n<\/li>\n<li>Install DBeaver Community Edition (CE).<br \/>\n<a title=\"dbeaver-ce-latest-installer.pkg\" href=\"https:\/\/dbeaver.io\/files\/dbeaver-ce-latest-installer.pkg\" target=\"_blank\" rel=\"noopener\">https:\/\/dbeaver.io\/files\/dbeaver-ce-latest-installer.pkg<\/a><\/li>\n<li>Connect to SQL Server using a client. In this tutorial, we will cover DBeaver.<\/li>\n<li>Run DBeaver.<\/li>\n<li>Select `Connect to database`.In the dialog box, select `SQL Server`.\n<ul>\n<li>Accept the default values.Host: <tt>`localhost`<\/tt><\/li>\n<li>Port: <tt>`1433`<\/tt><\/li>\n<li>Database\/schema: <tt>`master`<\/tt><\/li>\n<li>Authentication: <tt>`SQL Server Authentication`<\/tt><\/li>\n<li>User name: <tt>`sa`<\/tt><\/li>\n<li>Password: <tt>`&lt;YourStrong!Passw0rd&gt;`<\/tt><\/li>\n<li>Save password locally: <em>checked<\/em><\/li>\n<li>Trust Server Certificate: <em>checked<\/em><\/li>\n<li>Show All Schemas: <em>your choice, unchecked by default<\/em><\/li>\n<li>Advanced Settings: <tt>`Network settings (SSH, SSL...)`<\/tt> &amp; <tt>`Connection details (name, type...)`<\/tt><\/li>\n<li>Driver name: <tt>`MS SQL Server \/ Sql Server`<\/tt><\/li>\n<\/ul>\n<\/li>\n<li>At this point, you can test the connection or click the `Finish` button.<\/li>\n<\/ol>\n<p><strong>Resources<\/strong><\/p>\n<ul>\n<li><a title=\"MakeUseOf - How to Install Mac Apps in Terminal Using Homebrew\" href=\"https:\/\/www.makeuseof.com\/tag\/install-mac-software-terminal-homebrew\/\" target=\"_blank\" rel=\"noopener\">https:\/\/www.makeuseof.com\/tag\/install-mac-software-terminal-homebrew\/<\/a><\/li>\n<li><a title=\"Microsoft Docs - SQL Server - Get started with SQL Server containers on Docker (running SQL Server on Linux)\" href=\"https:\/\/docs.microsoft.com\/en-us\/sql\/linux\/quickstart-install-connect-docker?view=sql-server-2017\" target=\"_blank\" rel=\"noopener\">https:\/\/docs.microsoft.com\/en-us\/sql\/linux\/quickstart-install-connect-docker?view=sql-server-2017<\/a><\/li>\n<li><a title=\"DBeaver Community - Download\" href=\"https:\/\/dbeaver.io\/download\/\" target=\"_blank\" rel=\"noopener\">https:\/\/dbeaver.io\/download\/<\/a><\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>Instructions: Open `Terminal`. Application\/Utilities\/Terminal.app Install the Homebrew package manager system. \/usr\/bin\/ruby -e &#8220;$(curl -fsSL https:\/\/raw.githubusercontent.com\/Homebrew\/install\/master\/install)&#8221; Test Homebrew installation. brew doctor Install Docker using Homebrew. brew install docker Run Docker and download the latest package of SQL Server. sudo docker pull mcr.microsoft.com\/mssql\/server:2017-latest Accept the EULA (End-User Licensing Agreement) and enter a `sa` (system administrator) password (position [&hellip;]<\/p>\n","protected":false},"author":7213,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"send_to_group_blog":0,"footnotes":""},"categories":[3,1,17,2],"tags":[],"class_list":["post-842","post","type-post","status-publish","format-standard","hentry","category-computer-programming","category-cuny","category-open-source","category-sql"],"_links":{"self":[{"href":"https:\/\/folvera.commons.gc.cuny.edu\/index.php?rest_route=\/wp\/v2\/posts\/842","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/folvera.commons.gc.cuny.edu\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/folvera.commons.gc.cuny.edu\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/folvera.commons.gc.cuny.edu\/index.php?rest_route=\/wp\/v2\/users\/7213"}],"replies":[{"embeddable":true,"href":"https:\/\/folvera.commons.gc.cuny.edu\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=842"}],"version-history":[{"count":4,"href":"https:\/\/folvera.commons.gc.cuny.edu\/index.php?rest_route=\/wp\/v2\/posts\/842\/revisions"}],"predecessor-version":[{"id":847,"href":"https:\/\/folvera.commons.gc.cuny.edu\/index.php?rest_route=\/wp\/v2\/posts\/842\/revisions\/847"}],"wp:attachment":[{"href":"https:\/\/folvera.commons.gc.cuny.edu\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=842"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/folvera.commons.gc.cuny.edu\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=842"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/folvera.commons.gc.cuny.edu\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=842"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}