Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #41009 > unrolled thread

PyPyODBC 1.0.5 released. (DBI 2.0 ODBC module compatible with PyPy, IronPython and SQLAlchemy)

Started by江文 <jiangwen365@gmail.com>
First post2013-03-10 18:17 +0800
Last post2013-03-10 18:17 +0800
Articles 1 — 1 participant

Back to article view | Back to comp.lang.python


Contents

  PyPyODBC 1.0.5 released. (DBI 2.0 ODBC module compatible with PyPy, IronPython and SQLAlchemy) 江文 <jiangwen365@gmail.com> - 2013-03-10 18:17 +0800

#41009 — PyPyODBC 1.0.5 released. (DBI 2.0 ODBC module compatible with PyPy, IronPython and SQLAlchemy)

From江文 <jiangwen365@gmail.com>
Date2013-03-10 18:17 +0800
SubjectPyPyODBC 1.0.5 released. (DBI 2.0 ODBC module compatible with PyPy, IronPython and SQLAlchemy)
Message-ID<mailman.3150.1362910686.2939.python-list@python.org>

[Multipart message — attachments visible in raw view] — view raw

Changes in Ver 1.0.5 (and 1.0.4, 1.0.3, 1.0.2, 1.0.1)

   - *Fix several bugs under Python 3.x*
   - *Add Mac / iODBC platform support*
   - *Improved ODBC ANSI / unicode mode support*


Features

   - *One pure Python script, runs on CPython /
IronPython<https://code.google.com/p/pypyodbc/wiki/Enable_SQLAlchemy_on_IronPython>
    / PyPy <http://pypy.org/> , Python 3.3 / 2.4 / 2.5 / 2.6 / 2.7 , Win /
   Linux / Mac , 32 / 64 bit*
   - *Almost totally same usage as pyodbc <http://code.google.com/p/pyodbc>* (
   can be seen as a re-implementation of pyodbc in pure Python )
   - *Simple - the whole module is implemented in a single python script
   with less than 3000
lines<https://github.com/jiangwen365/pypyodbc/blob/master/pypyodbc.py>
   *
   - *Built-in functions<https://code.google.com/p/pypyodbc/wiki/pypyodbc_for_access_mdb_file>
to
   create and compress Access MDB files on Windows*

Simply try pypyodbc:

import pypyodbc

pypyodbc.win_create_mdb('D:\\database.mdb')

connection_string = 'Driver={Microsoft Access Driver
(*.mdb)};DBQ=D:\\database.mdb'

connection = pypyodbc.connect(connection_string)

SQL = 'CREATE TABLE saleout (id COUNTER PRIMARY KEY,product_name VARCHAR(25));'

connection.cursor().execute(SQL).commit()

...

Samples*A HelloWorld sample of python database
programming<https://code.google.com/p/pypyodbc/wiki/A_HelloWorld_sample_to_access_mssql_with_python>
**Create & Compact Access MDB
database<https://code.google.com/p/pypyodbc/wiki/pypyodbc_for_access_mdb_file>
*Install

*Download the latest package<http://code.google.com/p/pypyodbc/downloads/list>
* , unzip to a folder, *double click the setup.py file*, or run

setup.py install

Or if you have pip available:

pip install pypyodbc

Or get the latest pypyodbc.py script from
*GitHub<https://github.com/jiangwen365/pypyodbc>
* (Main Development site)

[toc] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web