/packages/sqlalchemy/doc/intro.html
HTML | 206 lines | 165 code | 41 blank | 0 comment | 0 complexity | 0d5b9b60959b893389f2fc4d17c18d6a MD5 | raw file
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
- <html>
- <head>
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
-
- <title>
- Overview / Installation
- — SQLAlchemy 0.6.4 Documentation</title>
-
- <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
- <link rel="stylesheet" href="_static/docs.css" type="text/css" />
- <script type="text/javascript">
- var DOCUMENTATION_OPTIONS = {
- URL_ROOT: '#',
- VERSION: '0.6.4',
- COLLAPSE_MODINDEX: false,
- FILE_SUFFIX: '.html'
- };
- </script>
- <script type="text/javascript" src="_static/jquery.js"></script>
- <script type="text/javascript" src="_static/underscore.js"></script>
- <script type="text/javascript" src="_static/doctools.js"></script>
- <script type="text/javascript" src="_static/init.js"></script>
- <link rel="index" title="Index" href="genindex.html" />
- <link rel="search" title="Search" href="search.html" />
- <link rel="copyright" title="Copyright" href="copyright.html" />
- <link rel="top" title="SQLAlchemy 0.6.4 Documentation" href="index.html" />
- <link rel="next" title="SQLAlchemy ORM" href="orm/index.html" />
- <link rel="prev" title="Table of Contents" href="index.html" />
-
- </head>
- <body>
-
- <h1>SQLAlchemy 0.6.4 Documentation</h1>
- <div id="search">
- Search:
- <form class="search" action="search.html" method="get">
- <input type="text" name="q" size="18" /> <input type="submit" value="Search" />
- <input type="hidden" name="check_keywords" value="yes" />
- <input type="hidden" name="area" value="default" />
- </form>
- </div>
- <div class="versionheader">
- Version: <span class="versionnum">0.6.4</span> Last Updated: 09/07/2010 13:07:48
- </div>
- <div class="clearboth"></div>
- <div class="topnav">
- <div id="pagecontrol">
- <a href="genindex.html">Index</a>
-
- <div class="sourcelink">(<a href="_sources/intro.txt">view source)</div>
- </div>
-
- <div class="navbanner">
- <a class="totoc" href="index.html">Table of Contents</a>
- »
- Overview / Installation
-
-
-
- <div class="prevnext">
- Previous:
- <a href="index.html" title="previous chapter">Table of Contents</a>
- Next:
- <a href="orm/index.html" title="next chapter">SQLAlchemy ORM</a>
- </div>
- <h2>
-
- Overview / Installation
-
- </h2>
- </div>
- <ul>
- <li><a class="reference internal" href="#">Overview / Installation</a><ul>
- <li><a class="reference internal" href="#overview">Overview</a></li>
- <li><a class="reference internal" href="#documentation-overview">Documentation Overview</a></li>
- <li><a class="reference internal" href="#code-examples">Code Examples</a></li>
- <li><a class="reference internal" href="#installing-sqlalchemy">Installing SQLAlchemy</a></li>
- <li><a class="reference internal" href="#installing-a-database-api">Installing a Database API</a></li>
- <li><a class="reference internal" href="#checking-the-installed-sqlalchemy-version">Checking the Installed SQLAlchemy Version</a></li>
- <li><a class="reference internal" href="#to-0-6-migration">0.5 to 0.6 Migration</a></li>
- </ul>
- </li>
- </ul>
- <div class="clearboth"></div>
- </div>
-
- <div class="document">
- <div class="body">
-
- <div class="section" id="overview-installation">
- <span id="overview-toplevel"></span><h1>Overview / Installation<a class="headerlink" href="#overview-installation" title="Permalink to this headline">¶</a></h1>
- <div class="section" id="overview">
- <h2>Overview<a class="headerlink" href="#overview" title="Permalink to this headline">¶</a></h2>
- <p>The SQLAlchemy SQL Toolkit and Object Relational Mapper is a comprehensive set of tools for working with databases and Python. It has several distinct areas of functionality which can be used individually or combined together. Its major components are illustrated below. The arrows represent the general dependencies of components:</p>
- <img alt="_images/sqla_arch_small.jpg" src="_images/sqla_arch_small.jpg" />
- <p>Above, the two most significant front-facing portions of SQLAlchemy are the <strong>Object Relational Mapper</strong> and the <strong>SQL Expression Language</strong>. SQL Expressions can be used independently of the ORM. When using the ORM, the SQL Expression language remains part of the public facing API as it is used within object-relational configurations and queries.</p>
- </div>
- <div class="section" id="documentation-overview">
- <h2>Documentation Overview<a class="headerlink" href="#documentation-overview" title="Permalink to this headline">¶</a></h2>
- <p>The documentation is separated into three sections: <a class="reference internal" href="orm/index.html"><em>SQLAlchemy ORM</em></a>, <a class="reference internal" href="core/index.html"><em>SQLAlchemy Core</em></a>, and <a class="reference internal" href="dialects/index.html"><em>Dialects</em></a>.</p>
- <p>In <a class="reference internal" href="orm/index.html"><em>SQLAlchemy ORM</em></a>, the Object Relational Mapper is introduced and fully
- described. New users should begin with the <a class="reference internal" href="orm/tutorial.html"><em>Object Relational Tutorial</em></a>. If you
- want to work with higher-level SQL which is constructed automatically for you,
- as well as management of Python objects, proceed to this tutorial.</p>
- <p>In <a class="reference internal" href="core/index.html"><em>SQLAlchemy Core</em></a>, the breadth of SQLAlchemy’s SQL and database
- integration and description services are documented, the core of which is the
- SQL Expression language. The SQL Expression Language is a toolkit all its own,
- independent of the ORM package, which can be used to construct manipulable SQL
- expressions which can be programmatically constructed, modified, and executed,
- returning cursor-like result sets. In contrast to the ORM’s domain-centric
- mode of usage, the expression language provides a schema-centric usage
- paradigm. New users should begin here with <a class="reference internal" href="core/tutorial.html"><em>SQL Expression Language Tutorial</em></a>.
- SQLAlchemy engine, connection, and pooling services are also described in
- <a class="reference internal" href="core/index.html"><em>SQLAlchemy Core</em></a>.</p>
- <p>In <a class="reference internal" href="dialects/index.html"><em>Dialects</em></a>, reference documentation for all provided
- database and DBAPI backends is provided.</p>
- </div>
- <div class="section" id="code-examples">
- <h2>Code Examples<a class="headerlink" href="#code-examples" title="Permalink to this headline">¶</a></h2>
- <p>Working code examples, mostly regarding the ORM, are included in the
- SQLAlchemy distribution. A description of all the included example
- applications is at <a class="reference internal" href="orm/examples.html"><em>Examples</em></a>.</p>
- <p>There is also a wide variety of examples involving both core SQLAlchemy
- constructs as well as the ORM on the wiki. See
- <a class="reference external" href="http://www.sqlalchemy.org/trac/wiki/UsageRecipes">http://www.sqlalchemy.org/trac/wiki/UsageRecipes</a>.</p>
- </div>
- <div class="section" id="installing-sqlalchemy">
- <h2>Installing SQLAlchemy<a class="headerlink" href="#installing-sqlalchemy" title="Permalink to this headline">¶</a></h2>
- <p>Installing SQLAlchemy from scratch is most easily achieved with <a class="reference external" href="http://pypi.python.org/pypi/setuptools/">setuptools</a>, or alternatively
- <a class="reference external" href="http://pypi.python.org/pypi/pip/">pip</a>. Assuming it’s installed, just run
- this from the command-line:</p>
- <div class="highlight-none"><div class="highlight"><pre># easy_install SQLAlchemy</pre></div>
- </div>
- <p>Or with pip:</p>
- <div class="highlight-none"><div class="highlight"><pre># pip install SQLAlchemy</pre></div>
- </div>
- <p>This command will download the latest version of SQLAlchemy from the <a class="reference external" href="http://pypi.python.org/pypi/SQLAlchemy">Python
- Cheese Shop</a> and install it to your
- system.</p>
- <p>Otherwise, you can install from the distribution using the <tt class="docutils literal"><span class="pre">setup.py</span></tt> script:</p>
- <div class="highlight-none"><div class="highlight"><pre># python setup.py install</pre></div>
- </div>
- </div>
- <div class="section" id="installing-a-database-api">
- <h2>Installing a Database API<a class="headerlink" href="#installing-a-database-api" title="Permalink to this headline">¶</a></h2>
- <p>SQLAlchemy is designed to operate with a <a class="reference external" href="http://www.python.org/doc/peps/pep-0249/">DB-API</a> implementation built for a particular database, and includes support for the most popular databases. The current list is at <a class="reference internal" href="core/engines.html#supported-dbapis"><em>Supported Databases</em></a>.</p>
- </div>
- <div class="section" id="checking-the-installed-sqlalchemy-version">
- <h2>Checking the Installed SQLAlchemy Version<a class="headerlink" href="#checking-the-installed-sqlalchemy-version" title="Permalink to this headline">¶</a></h2>
- <p>This documentation covers SQLAlchemy version 0.6. If you’re working on a system that already has SQLAlchemy installed, check the version from your Python prompt like this:</p>
- <div class="highlight-python+sql"><div class="highlight"><pre><span class="o">>>></span> <span class="kn">import</span> <span class="nn">sqlalchemy</span>
- <span class="o">>>></span> <span class="n">sqlalchemy</span><span class="o">.</span><span class="n">__version__</span>
- <span class="mf">0.6</span><span class="o">.</span><span class="mi">0</span></pre></div>
- </div>
- </div>
- <div class="section" id="to-0-6-migration">
- <h2>0.5 to 0.6 Migration<a class="headerlink" href="#to-0-6-migration" title="Permalink to this headline">¶</a></h2>
- <p>Notes on what’s changed from 0.5 to 0.6 is available on the SQLAlchemy wiki at <a class="reference external" href="http://www.sqlalchemy.org/trac/wiki/06Migration">06Migration</a>.</p>
- </div>
- </div>
- </div>
- </div>
-
-
- <div class="bottomnav">
-
- <div class="prevnext">
- Previous:
- <a href="index.html" title="previous chapter">Table of Contents</a>
- Next:
- <a href="orm/index.html" title="next chapter">SQLAlchemy ORM</a>
- </div>
- <div class="doc_copyright">
- © <a href="copyright.html">Copyright</a> 2007, 2008, 2009, 2010, the SQLAlchemy authors and contributors.
- Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.0.1.
- </div>
- </div>
-
- </body>
- </html>