summaryrefslogtreecommitdiff
path: root/lib
Commit message (Collapse)AuthorAgeFilesLines
* - Fixed recursion bug which could occur when movingMike Bayer2010-09-133-9/+9
| | | | | | | an object from one reference to another, with backrefs involved, where the initiating parent was a subclass (with its own mapper) of the previous parent.
* more docs on thisMike Bayer2010-09-122-13/+17
|
* need this tooMike Bayer2010-09-121-0/+2
|
* - lazy loads for relationship attributes now useMike Bayer2010-09-129-59/+130
| | | | | | | | | | | | | | | | | | | | | the current state, not the "committed" state, of foreign and primary key attributes when issuing SQL, if a flush is not in process. Previously, only the database-committed state would be used. In particular, this would cause a many-to-one get()-on-lazyload operation to fail, as autoflush is not triggered on these loads when the attributes are determined and the "committed" state may not be available. [ticket:1910] - A new flag on relationship(), load_on_pending, allows the lazy loader to fire off on pending objects without a flush taking place, as well as a transient object that's been manually "attached" to the session. Note that this flag blocks attribute events from taking place when an object is loaded, so backrefs aren't available until after a flush. The flag is only intended for very specific use cases.
* - Slight improvement to the behavior of "passive_updates=False"Mike Bayer2010-09-122-5/+12
| | | | | | | | | | | when placed only on the many-to-one side of a relationship; documentation has been clarified that passive_updates=False should really be on the one-to-many side. - Placing passive_deletes=True on a many-to-one emits a warning, since you probably intended to put it on the one-to-many side.
* - collection docsMike Bayer2010-09-093-5/+14
| | | | | | | | - Added an assertion during flush which ensures that no NULL-holding identity keys were generated on "newly persistent" objects. This can occur when user defined code inadvertently triggers flushes on not-fully-loaded objects.
* - add doc pages for exceptionsMike Bayer2010-09-092-3/+3
|
* doc editsMike Bayer2010-09-081-13/+23
|
* editsMike Bayer2010-09-082-13/+13
|
* - Applied patches from [ticket:1904] to getrel_0_6_4Mike Bayer2010-09-072-22/+16
| | | | | | basic Informix functionality up again. We rely upon end-user testing to ensure that Informix is working to some degree.
* - Added a mutex to the identity map which mutexesMike Bayer2010-09-071-28/+49
| | | | | | | | remove operations against iteration methods, which now pre-buffer before returning an iterable. This because asyncrhonous gc can remove items via the gc thread at any time. [ticket:1891]
* - pending deprecation in 0.7 for the execute/scalar on clauseelementMike Bayer2010-09-073-9/+11
|
* - Fixed FB bug whereby a column default would fail toMike Bayer2010-09-061-1/+2
| | | | reflect if the "default" keyword were lower case.
* unify query.with_parent, util.with_parent, fix docs some moreMike Bayer2010-09-062-50/+46
|
* doc updatesMike Bayer2010-09-064-10/+58
|
* merge doc fixes from tipMike Bayer2010-09-061-1/+1
|\
| * fixesMike Bayer2010-09-051-1/+1
| |
* | - query.with_parent() now accepts transient objectsMike Bayer2010-09-063-31/+68
|/ | | | | | | and will use the non-persistent values of their pk/fk attributes in order to formulate the criterion. Docs are also clarified as to the purpose of with_parent(). - fix for PG test executing an alias()
* merge tipMike Bayer2010-09-052-0/+13
|\
| * - mapper _get_col_to_prop private method usedMike Bayer2010-09-052-0/+13
| | | | | | | | | | | | | | | | by the versioning example is deprecated; now use mapper.get_property_by_column() which will remain the public method for this. - turned TODO in the history example into an assertion with a descriptive reason
* | fixupMike Bayer2010-09-051-7/+7
| |
* | - rewrote the "connections" sectionMike Bayer2010-09-054-20/+130
| | | | | | | | | | | | | | | | | | - improved pool docs - typos etc. - ClauseElement.execute() and scalar() make no sense - these are depreacted. The official home is Executable. - alias() is not executable, allowing it is sloppy so this goes under the deprecated umbrella
* | roughly the finished product.Mike Bayer2010-09-044-23/+85
| |
* | almost through.Mike Bayer2010-09-048-82/+111
| |
* | continued...Mike Bayer2010-09-043-15/+32
| |
* | experiment with removing the API section and putting docstrings inline.Mike Bayer2010-09-042-8/+8
|/ | | | new outline section is provided with a new flow.
* python 2.4Mike Bayer2010-09-031-13/+15
|
* Apply more memoization to Mapper attributes & subject to group expiry.Jason Kirtland2010-09-037-64/+129
|
* - AbstractType.__str__() produces the string version of the type with ↵Mike Bayer2010-09-031-130/+175
| | | | | | default dialect - 79 chars
* - a large hill to climb. Added declarative examples to all theMike Bayer2010-08-301-1/+2
| | | | | | | | | | | | | | "basic relationship" examples, cleaned up the examples and added some more explicitness. Also renamed "treenodes" to "nodes" and added self-referential declarative example. - Added info/examples on how to join tables directly when querying with joined table inheritance. - Starting to talk about hybrids in the main mapper docs some more. introducoed the idea that synonyms are on their way out. - SQL expressions as mapped attributes also gets better verbiage, alternative approaches to them, including hybrids. - modernized the hybrid example. - object_session() as a standalone function wasn't documented ?!
* - The include_properties and exclude_properties argumentsMike Bayer2010-08-304-37/+77
| | | | | | | | | | | | | | | | | | | | | | | | | | | | to mapper() now accept Column objects as members in addition to strings. This so that same-named Column objects, such as those within a join(), can be disambiguated. - A warning is now emitted if a mapper is created against a join or other single selectable that includes multiple columns with the same name in its .c. collection, and those columns aren't explictly named as part of the same or separate attributes (or excluded). In 0.7 this warning will be an exception. Note that this warning is not emitted when the combination occurs as a result of inheritance, so that attributes still allow being overridden naturally. [ticket:1896]. In 0.7 this will be improved further. - The primary_key argument to mapper() can now specify a series of columns that are only a subset of the calculated "primary key" columns of the mapped selectable, without an error being raised. This helps for situations where a selectable's effective primary key is simpler than the number of columns in the selectable that are actually marked as "primary_key", such as a join against two tables on their primary key columns [ticket:1896].
* doc tweakMike Bayer2010-08-291-2/+2
|
* - The Session class is now present in sqlalchemy.orm.*.Mike Bayer2010-08-291-2/+3
| | | | | | | | We're moving away from the usage of create_session(), which has non-standard defaults, for those situations where a one-step Session constructor is desired. Most users should stick with sessionmaker() for general use, however.
* - Oracle reflection of indexes has been tuned soMike Bayer2010-08-292-6/+31
| | | | | | | | | | | | | | | | | that indexes which include some or all primary key columns, but not the same set of columns as that of the primary key, are reflected. Indexes which contain the identical columns as that of the primary key are skipped within reflection, as the index in that case is assumed to be the auto-generated primary key index. Previously, any index with PK columns present would be skipped. Thanks to Kent Bower for the patch. [ticket:1867] - Oracle now reflects the names of primary key constraints - also thanks to Kent Bower. [ticket:1868]
* docstring for query.correlate, [ticket:1889]Mike Bayer2010-08-292-6/+25
|
* - Added ROWID type to the Oracle dialect, for thoseMike Bayer2010-08-293-1/+19
| | | | | cases where an explicit CAST might be needed. [ticket:1879]
* - put a link to the wiki table config exampleMike Bayer2010-08-271-1/+3
|
* - An object that's been deleted now gets a flagMike Bayer2010-08-262-5/+20
| | | | | | | | | | | | 'deleted', which prohibits the object from being re-add()ed to the session, as previously the object would live in the identity map silently until its attributes were accessed. The make_transient() function now resets this flag along with the "key" flag. - make_transient() can be safely called on an already transient instance.
* - replaced all self.__connection.is_valid withMike Bayer2010-08-261-14/+22
| | | | | | | | | | | "safe" self._connection_is_valid. - Fixed bug in Connection whereby if a "disconnect" event occurred in the "initialize" phase of the first connection pool connect, an AttributeError would be raised when the Connection would attempt to invalidate the DBAPI connection. [ticket:1894] - Connection.invalidate() can be called more than once and subsequent calls do nothing.
* some doc updatesMike Bayer2010-08-241-3/+7
|
* - Similarly, for relationship(), foreign_keys,Mike Bayer2010-08-213-9/+11
| | | | | | | remote_side, order_by - all column-based expressions are enforced - lists of strings are explicitly disallowed since this is a very common error
* - object_session() raises the properMike Bayer2010-08-181-2/+10
| | | | | UnmappedInstanceError when presented with an unmapped instance. [ticket:1881]
* - 79 chars for expressionMike Bayer2010-08-141-428/+559
| | | | - fix typo in test
* - Another pass through the series of error messagesMike Bayer2010-08-144-90/+130
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | emitted when relationship() is configured with ambiguous arguments. The "foreign_keys" setting is no longer mentioned, as it is almost never needed and it is preferable users set up correct ForeignKey metadata, which is now the recommendation. If 'foreign_keys' is used and is incorrect, the message suggests the attribute is probably unnecessary. Docs for the attribute are beefed up. This because all confused relationship() users on the ML appear to be attempting to use foreign_keys due to the message, which only confuses them further since Table metadata is much clearer. - If the "secondary" table has no ForeignKey metadata and no foreign_keys is set, even though the user is passing screwed up information, it is assumed that primary/secondaryjoin expressions should consider only and all cols in "secondary" to be foreign. It's not possible with "secondary" for the foreign keys to be elsewhere in any case. A warning is now emitted instead of an error, and the mapping succeeds. [ticket:1877] - fixed incorrect "Alternate Collection Mappings" reference in the docs, not sure if someone wants to reference "Rows that Point to Themselves" function - "Collection Mapping" is "Advanced Collection Mapping", this section is troublesome since nobody really needs it but it is public API
* - Added basic math expression coercion forMike Bayer2010-08-131-0/+5
| | | | | | Numeric->Integer, so that resulting type is Numeric regardless of the direction of the expression.
* - added much more verbiage about transactions and expire_allMike Bayer2010-08-121-8/+48
|
* spelling argMike Bayer2010-08-111-1/+1
|
* - a warning is emitted in mapper() if the polymorphic_onMike Bayer2010-08-111-0/+7
| | | | | | | | column is not present either in direct or derived form in the mapped selectable or in the with_polymorphic selectable, instead of silently ignoring it. Look for this to become an exception in 0.7.
* - Fixed the psycopg2 dialect to use itsMike Bayer2010-08-102-17/+63
| | | | | | | set_isolation_level() method instead of relying upon the base "SET SESSION ISOLATION" command, as psycopg2 resets the isolation level on each new transaction otherwise.
* get slightly better about deprecations in docstrings, tho this is kind of an ↵Mike Bayer2010-08-096-21/+50
| | | | uphill climb