From 7a15313c9e42bfcdd03b79a8edf3d0a7eb97d78d Mon Sep 17 00:00:00 2001 From: Mike Bayer Date: Sat, 26 Aug 2006 18:55:05 +0000 Subject: [PATCH] fixed inaccuracies regarding "connectable" parameter sent to create/drop --- doc/build/content/metadata.txt | 4 ++-- doc/build/content/unitofwork.txt | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/doc/build/content/metadata.txt b/doc/build/content/metadata.txt index b9e16f41f8..171b395941 100644 --- a/doc/build/content/metadata.txt +++ b/doc/build/content/metadata.txt @@ -266,7 +266,7 @@ Many table, schema, or column names require quoting to be enabled. Reasons for ### Creating and Dropping Database Tables {@name=creating} -Creating and dropping individual tables can be done via the `create()` and `drop()` methods of `Table`; these methods take an optional `engine` parameter which references an `Engine` or a `Connection`. If not supplied, the `Engine` bound to the `MetaData` will be used, else an error is raised: +Creating and dropping individual tables can be done via the `create()` and `drop()` methods of `Table`; these methods take an optional `connectable` parameter which references an `Engine` or a `Connection`. If not supplied, the `Engine` bound to the `MetaData` will be used, else an error is raised: {python} meta = BoundMetaData('sqlite:///:memory:') @@ -296,7 +296,7 @@ The `create()` and `drop()` methods also support an optional keyword argument `c employees.create(connectable=e, checkfirst=True) employees.drop(checkfirst=False) -Entire groups of Tables can be created and dropped directly from the `MetaData` object with `create_all()` and `drop_all()`. These methods always check for the existence of each table before creating or dropping. Each method takes an optional `engine` keyword argument which can reference an `Engine` or a `Connection`. If no engine is specified, the underlying bound `Engine`, if any, is used: +Entire groups of Tables can be created and dropped directly from the `MetaData` object with `create_all()` and `drop_all()`. These methods always check for the existence of each table before creating or dropping. Each method takes an optional `connectable` keyword argument which can reference an `Engine` or a `Connection`. If no engine is specified, the underlying bound `Engine`, if any, is used: {python} engine = create_engine('sqlite:///:memory:') diff --git a/doc/build/content/unitofwork.txt b/doc/build/content/unitofwork.txt index 8319ecd09f..8f49ad896a 100644 --- a/doc/build/content/unitofwork.txt +++ b/doc/build/content/unitofwork.txt @@ -72,7 +72,7 @@ It is possible to install a default "threadlocal" session context by importing a objectstore.flush() # which is the same as this (assuming we are still on the same thread): - session = objectstore.get_session() + session = objectstore.session session.flush() We will now cover some of the key concepts used by Sessions and its underlying Unit of Work. -- 2.47.2