title: How can I access a SQL file while using python?
body: <p>Right now I'm using Microsoft SQL Community to start a database, but for some reason I can't command the server to do something that I want, is there any to use the library <strong>sqlite3</strong> or <strong>pyodc</strong> to print a value that I want on the console?</p>
  <h2>PYTHON:</h2>
  <pre class="lang-py prettyprint-override"><code>connection = sqlite3.connect(&quot;REPLICATED_STORAGE.db&quot;)
  cursor = connection.cursor()
  
  sql_file = open(&quot;Template.sql&quot;)
  sql_as_string = sql_file.read()
  cursor.executescript(sql_as_string)
  
  for row in cursor.execute(&quot;SELECT * FROM FRUITS&quot;):
      print(row)
  </code></pre>
  <h1>SQL:</h1>
  <pre class="lang-sql prettyprint-override"><code>USE [REPLICATED_STORAGE]
  GO
  
  SET ANSI_NULLS ON
  GO
  
  SET QUOTED_IDENTIFIER ON
  GO
  
  CREATE TABLE [dbo].[FRUITS](
      [COLOR] [nchar](10) NOT NULL,
      [TYPE] [nchar](10) NULL,
      [NAME] [nchar](10) NULL,
      [WEIGHT] [nchar](10) NULL
  ) ON [PRIMARY]
  GO
  
  </code></pre>