<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>SQL Using Python MSSQL-CLI - MSSQL Query</title>
	<atom:link href="https://mssqlquery.com/tag/sql-using-python-mssql-cli/feed" rel="self" type="application/rss+xml" />
	<link>https://mssqlquery.com</link>
	<description>MSSQL and TSQL Programming and TSQL Examples</description>
	<lastBuildDate>Wed, 22 Mar 2023 21:31:28 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.3.1</generator>

<image>
	<url>https://mssqlquery.com/wp-content/uploads/2023/06/cropped-mssql-query-icon-32x32.png</url>
	<title>SQL Using Python MSSQL-CLI - MSSQL Query</title>
	<link>https://mssqlquery.com</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Using Python MSSQL-CLI in SQL Server</title>
		<link>https://mssqlquery.com/using-python-mssql-cli-in-sql-server</link>
		
		<dc:creator><![CDATA[Yavuz Selim Kart]]></dc:creator>
		<pubDate>Sun, 31 Oct 2021 20:02:09 +0000</pubDate>
				<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[Python MSSQL-CLI]]></category>
		<category><![CDATA[SQL Using Python MSSQL-CLI]]></category>
		<category><![CDATA[Using Python MSSQL-CLI]]></category>
		<guid isPermaLink="false">https://mssqlquery.com/?p=260</guid>

					<description><![CDATA[<p>Hello to everyone, In this article, I will try to give information about using Python MSSQL-CLI in SQL Server. First, let me talk about what MSSQL-CLI is. MSSQL-CLI is an interactive command line query tool for SQL Server. It is open source and built with Python. It can be used&#46;&#46;&#46;</p>
<p>The post <a href="https://mssqlquery.com/using-python-mssql-cli-in-sql-server">Using Python MSSQL-CLI in SQL Server</a> first appeared on <a href="https://mssqlquery.com">MSSQL Query</a>.</p>]]></description>
										<content:encoded><![CDATA[<p>Hello to everyone,</p>
<p>In this article, I will try to give information about using Python MSSQL-CLI in SQL Server.</p>
<p>First, let me talk about what MSSQL-CLI is.</p>
<p>MSSQL-CLI is an interactive command line query tool for SQL Server. It is open source and built with Python. It can be used easily on MSDOS. It has autocomplete feature on MSDOS.</p>
<p>You don&#8217;t need to know Python to do the operations. It is important that you <a href="https://www.python.org/downloads/">download</a> and install the 3.10.</p>
<p>If you have done the Python installation, it&#8217;s time to install MSSQL-CLI.</p>
<p>Let&#8217;s go to the site below.</p>
<p><strong>https://pypi.org/project/mssql-cli/</strong></p>
<p><img decoding="async" fetchpriority="high" class="alignnone wp-image-262 size-full" src="https://mssqlquery.com/wp-content/uploads/2021/10/using-python-mssql-cli-in-sql-server-1.jpg" alt="Using Python MSSQL-CLI in SQL Server" width="700" height="377" srcset="https://mssqlquery.com/wp-content/uploads/2021/10/using-python-mssql-cli-in-sql-server-1.jpg 700w, https://mssqlquery.com/wp-content/uploads/2021/10/using-python-mssql-cli-in-sql-server-1-300x162.jpg 300w" sizes="(max-width: 700px) 100vw, 700px" /></p>
<p>Copy the part in the red area, paste it into MSDOS and press ENTER. You will see a process similar to the one below.</p>
<p><img decoding="async" class="alignnone wp-image-263 size-full" src="https://mssqlquery.com/wp-content/uploads/2021/10/using-python-mssql-cli-in-sql-server-2.jpg" alt="Using Python MSSQL-CLI in SQL Server" width="700" height="366" srcset="https://mssqlquery.com/wp-content/uploads/2021/10/using-python-mssql-cli-in-sql-server-2.jpg 700w, https://mssqlquery.com/wp-content/uploads/2021/10/using-python-mssql-cli-in-sql-server-2-300x157.jpg 300w" sizes="(max-width: 700px) 100vw, 700px" /></p>
<p>The yellow warning is a warning that our Pip version is out of date. If you wish, you can update our version of Pip as indicated by the warning.</p>
<p>The installation process is complete. Now it&#8217;s time to use it.</p>
<pre class="line-numbers"><code class="language-markup">mssql-cli -S YAVUZSELIM\YAVUZSELIM -d Northwind -U sa -P WriteyourownPassword</code></pre>
<p>&nbsp;</p>
<p>Press ENTER after typing the command. You will see the result below.</p>
<p>YAVUZSELIM\YAVUZSELIM is my SQL Server login INSTANCE NAME name. Northwind database name. sa user login name. Finally, you will revise your sa password above according to yourself.</p>
<p><img decoding="async" class="alignnone wp-image-264 size-full" src="https://mssqlquery.com/wp-content/uploads/2021/10/using-python-mssql-cli-in-sql-server-3.jpg" alt="Using Python MSSQL-CLI in SQL Server" width="700" height="366" srcset="https://mssqlquery.com/wp-content/uploads/2021/10/using-python-mssql-cli-in-sql-server-3.jpg 700w, https://mssqlquery.com/wp-content/uploads/2021/10/using-python-mssql-cli-in-sql-server-3-300x157.jpg 300w" sizes="(max-width: 700px) 100vw, 700px" /></p>
<p>Now let&#8217;s write our query.</p>
<p><img decoding="async" loading="lazy" class="alignnone wp-image-265 size-full" src="https://mssqlquery.com/wp-content/uploads/2021/10/using-python-mssql-cli-in-sql-server-4.jpg" alt="Using Python MSSQL-CLI in SQL Server" width="700" height="366" srcset="https://mssqlquery.com/wp-content/uploads/2021/10/using-python-mssql-cli-in-sql-server-4.jpg 700w, https://mssqlquery.com/wp-content/uploads/2021/10/using-python-mssql-cli-in-sql-server-4-300x157.jpg 300w" sizes="(max-width: 700px) 100vw, 700px" /></p>
<p>I typed the query and pressed ENTER. If the result is too much, you can see the rest by pressing the SPACE button. I also added a gif image related to its usage below. You can review.</p>
<p><img decoding="async" loading="lazy" class="alignnone wp-image-266 size-full" src="https://mssqlquery.com/wp-content/uploads/2021/10/using-python-mssql-cli-in-sql-server-5.gif" alt="Using Python MSSQL-CLI in SQL Server" width="756" height="338" /></p>
<p>As you can see, we have successfully run our query using Python MSSQL-CLI.</p>
<p>Good luck to everyone in business and life.</p>
<div class='epvc-post-count'><span class='epvc-eye'></span>  <span class="epvc-count"> 379</span><span class='epvc-label'> Views</span></div><p>The post <a href="https://mssqlquery.com/using-python-mssql-cli-in-sql-server">Using Python MSSQL-CLI in SQL Server</a> first appeared on <a href="https://mssqlquery.com">MSSQL Query</a>.</p>]]></content:encoded>
					
		
		
			</item>
	</channel>
</rss>
