summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/schema.py
Commit message (Collapse)AuthorAgeFilesLines
...
* - schema.copy() functions will copy dispatch, but only for those eventsMike Bayer2011-02-011-5/+16
| | | | | | | | | added with propagate=True. needs tests - oracle/fb test schema uses event w/ propagate=True to apply Sequence to primary key columns with test_needs_autoincrement. this does actually test the propagate=True flag a bit since it's needed in the declarative mixin tests where the 'id' column is copied.
* - SchemaItem, SchemaType now descend from common typeMike Bayer2011-01-301-38/+23
| | | | | | | | | | | | | | | | | | SchemaEventTarget, which supplies dispatch - the dispatch now provides before_parent_attach(), after_parent_attach(), events which generally bound the _set_parent() event. [ticket:2037] - the _on_table_attach mechanism now usually uses the event dispatch - fixed class-level event dispatch to propagate to all subclasses, not just immediate subclasses - fixed class-level event unpickling to handle more involved inheritance hierarchies, needed by the new schema event dispatch. - ForeignKeyConstraint doesn't re-call the column attach event on ForeignKey objects that are already associated with the correct Column - we still need that ImportError on mysqldb CLIENT FLAGS to support mock DBAPIs
* - Column.copy(), as used in table.tometadata(), copies theMike Bayer2011-01-301-0/+1
| | | | 'doc' attribute. [ticket:2028]
* rename 'frozendict' to 'immutabledict', since 'frozen' implies hashabilityMike Bayer2011-01-201-1/+1
| | | | | like frozenset which isn't really the purpose of 'immutabledict' (could be someday, in which case, we'd change the name back :) )
* - getting slightly more consistent behavior for the edge case of pk columnsMike Bayer2011-01-151-6/+7
| | | | | | with server default - autoincrement is now false with any server_default, so these all return None, applies consistency to [ticket:2020], [ticket:2021]. if prefetch is desired a "default" should be used instead of server_default.
* - dont count server_default absense as part of autoincrement, PGMike Bayer2011-01-121-3/+5
| | | | | | will have a value here upon reflection. - mysql, others will have to check "server_default" when rendering special keywords like AUTOINCREMENT
* - A TypeDecorator of Integer can be used with a primary keyMike Bayer2011-01-111-3/+4
| | | | | | | | | | | | | | | | | | | column, and the "autoincrement" feature of various dialects as well as the "sqlite_autoincrement" flag will honor the underlying database type as being Integer-based. [ticket:2005] - Result-row processors are applied to pre-executed SQL defaults, as well as cursor.lastrowid, when determining the contents of result.inserted_primary_key. [ticket:2006] - Bind parameters present in the "columns clause" of a select are now auto-labeled like other "anonymous" clauses, which among other things allows their "type" to be meaningful when the row is fetched, as in result row processors. - TypeDecorator is present in the "sqlalchemy" import space.
* - merge r43460573c27a:4993c7eae8e5d117ff342bdc59f3b0635b898e2c of 0.6 branchMike Bayer2011-01-081-1/+5
|
* - The Index() construct can be created inline with a TableMike Bayer2011-01-041-33/+46
| | | | | definition, using strings as column names, as an alternative to the creation of the index outside of the Table.
* - whitespace removal bonanzaMike Bayer2011-01-021-199/+199
|
* - clean up copyright, update for 2011, stamp every file withMike Bayer2011-01-021-3/+2
| | | | | a consistent tag - AUTHORS file
* - removes the "on_" prefix.Mike Bayer2010-12-301-9/+9
|
* - remove OrderedSet usage from a critical areaMike Bayer2010-12-221-3/+3
|
* skip some len callsMike Bayer2010-12-191-1/+1
|
* - inliningsMike Bayer2010-12-161-1/+5
| | | | - in particular, mapper.primary_key is a tuple now
* - why type.dialect_impl(dialect).bind_processor(dialect), caching just the impl?Mike Bayer2010-12-131-3/+3
| | | | | | just call type._cached_bind_processor(dialect), cache the impl *and* the processor function. same for result sets. - use plain dict + update for defaultexecutioncontext.execution_options
* new calling style: event.listen(target, identifier, fn)Mike Bayer2010-12-011-13/+11
|
* - merge FromObj cleanup, immutable .c attribute patch, [ticket:1917]Mike Bayer2010-11-201-10/+9
|\
| * - adapt initial patch from [ticket:1917] to current tipMike Bayer2010-11-161-10/+9
| | | | | | | | - raise TypeError for immutability
* | - merge metadata/schema/declarative branch, [ticket:1893]Mike Bayer2010-11-201-9/+24
|\ \
| * | [ticket:1893] implementationMike Bayer2010-11-151-9/+24
| |/
* | merge tipMike Bayer2010-11-141-0/+1
|\ \ | |/
| * - The 'info' attribute of Column is copied duringMike Bayer2010-11-141-0/+1
| | | | | | | | | | Column.copy(), i.e. as occurs when using columns in declarative mixins. [ticket:1967]
* | merge tipMike Bayer2010-11-131-13/+6
|\ \ | |/
| * - move inline "import" statements to use new "util.importlater()" construct. ↵Mike Bayer2010-11-131-13/+6
| | | | | | | | | | | | | | | | | | cuts down on clutter, timeit says there's a teeny performance gain, at least where the access is compared against attr.subattr. these aren't super-critical calls anyway - slight inlining in _class_to_mapper
* | more docsMike Bayer2010-11-101-3/+31
| |
* | - move deprecated interfaces down to bottom of TOC, update verbiageMike Bayer2010-11-101-12/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | - more docs for engine, pool, DDL events - update DDL sequences documentation to use events - update DDL() docstring to refer to execute_if() - document parameters for DDLElement.execute_if() - add retval=True flag to Engine.on_before_execute(), on_before_cursor_execute(). wrap the function if retval=False, check for appropriate usage of the flag, add tests. - remove ScopedSession.mapper and tests entirely - remove ExtensionCarrier and tests - change remaining tests that use MapperExtension to use MapperEvents
* | - merge tipMike Bayer2010-11-061-2/+10
|\ \ | |/
| * - added "views=True" option to metadata.reflect(),Mike Bayer2010-10-021-2/+10
| | | | | | | | | | will add the list of available views to those being reflected. [ticket:1936]
* | merge tipMike Bayer2010-10-021-11/+31
|\ \ | |/
| * - An informative error message is raised if a ColumnMike Bayer2010-09-181-0/+4
| | | | | | | | | | | | | | | | | | which has not yet been assigned a name, i.e. as in declarative, is used in a context where it is exported to the columns collection of an enclosing select() construct, or if any construct involving that column is compiled before its name is assigned. [ticket:1862]
| * - use "key in dict" rather than KeyError if the usual caseMike Bayer2010-09-181-37/+28
| | | | | | | | | | | | | | | | is that the key is not present. - don't need to uniquify Index schemes, just don't copy Indexes that were known to be generated from the index=True flag - user facing changes go in CHANGES - Table.c allows string lookup
| * add warning about dodgy use of tometadataChris Withers2010-09-161-1/+5
| |
| * tometadata now copies indexes as wellChris Withers2010-09-161-1/+22
| |
| * make sure kwargs are copied by tometadataChris Withers2010-09-161-1/+1
| |
* | - reorganizationMike Bayer2010-09-141-30/+7
| | | | | | | | | | | | | | - attrbutes.py splits into attribtes.py and instrumentation.py - all the various Event subclasses go into events.py modules - some ideas for orm events - move *Extension out to deprecated_interfaces
* | - merge tip, 0.6.4 + 0.6.5Mike Bayer2010-09-141-7/+69
|\ \ | |/
| * roughly the finished product.Mike Bayer2010-09-041-2/+2
| |
| * almost through.Mike Bayer2010-09-041-5/+67
| |
* | restore the deprecated docsMike Bayer2010-09-041-2/+60
| |
* | - refinements to DDL events, including new execute_if(), got pickling to workMike Bayer2010-09-031-76/+78
| |
* | doh, forgot about ddl events. need some work with the pickling.Mike Bayer2010-08-311-82/+45
|/
* get slightly better about deprecations in docstrings, tho this is kind of an ↵Mike Bayer2010-08-091-2/+9
| | | | uphill climb
* - Fixed bug whereby replacing composite foreign keyMike Bayer2010-08-041-1/+5
| | | | | | | | columns in a reflected table would cause an attempt to remove the reflected constraint from the table a second time, raising a KeyError. [ticket:1865] - fixed test of error message now that we've improved it (didn't know that msg had an assertion)
* - Added full description of parent table/column,Mike Bayer2010-08-031-2/+3
| | | | | target table/column in error message raised when ForeignKey can't resolve target.
* - add an example of declarative with hybrid, including why thisMike Bayer2010-08-021-5/+37
| | | | | is a different use case (i.e. formalized apps vs. quickstart). - solidified docstrings for ForeignKey
* - Changed the scheme used to generate truncatedMike Bayer2010-07-211-1/+1
| | | | | | | | | | | | "auto" index names when using the "index=True" flag on Column. The truncation only takes place with the auto-generated name, not one that is user-defined (an error would be raised instead), and the truncation scheme itself is now based on a fragment of an md5 hash of the identifier name, so that multiple indexes on columns with similar names still have unique names. [ticket:1855]
* - more 78 charsMike Bayer2010-07-101-174/+223
| | | | | - BIGINT doc - clean up docs in schema.py
* - Column.copy() takes along the "unique" attributeMike Bayer2010-06-151-0/+1
| | | | | among others, fixes [ticket:1829] regarding declarative mixins
* disclaimer for the "type=None" semi-featureMike Bayer2010-05-151-3/+5
|