summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy
Commit message (Collapse)AuthorAgeFilesLines
* - [bug] Added support for using the .keyMike Bayer2012-02-052-13/+42
| | | | | | | | | | | | of a Column as a string identifier in a result set row. The .key is currently listed as an "alternate" name for a column, and is superseded by the name of a column which has that key value as its regular name. For the next major release of SQLAlchemy we may reverse this precedence so that .key takes precedence, but this is not decided on yet. [ticket:2392]
* - [bug] A significant change to how labelingMike Bayer2012-02-058-58/+111
| | | | | | | | | | | | | | is applied to columns in SELECT statements allows "truncated" labels, that is label names that are generated in Python which exceed the maximum identifier length (note this is configurable via label_length on create_engine()), to be properly referenced when rendered inside of a subquery, as well as to be present in a result set row using their original in-Python names. [ticket:2396] - apply pep8 to test_labels
* - add a warning regarding tuple.in_(), [ticket:2395]Mike Bayer2012-02-042-7/+24
| | | | - cleanup of exc.DBAPIError docstrings
* accept the symbols so recreate worksMike Bayer2012-02-011-4/+5
|
* - [feature] Added pool_reset_on_return argumentMike Bayer2012-02-013-8/+56
| | | | | | | | to create_engine, allows control over "connection return" behavior. Also added new arguments 'rollback', 'commit', None to pool.reset_on_return to allow more control over connection return activity. [ticket:2378]
* fix an inadvertent abuse of variable scopeMike Bayer2012-01-311-1/+2
|
* break out _save_obj(), _delete_obj(), _post_update() into a new moduleMike Bayer2012-01-304-629/+793
| | | | | | | persistence.py - Mapper loses awareness of how to emit INSERT/UPDATE/DELETE, persistence.py is only used by unitofwork.py. Then break each method out into a top level with almost no logic, calling into _organize_states_for_XYZ(), _collect_XYZ_commands(), _emit_XYZ_statements().
* - [bug] Scaled back the test applied withinMike Bayer2012-01-301-10/+9
| | | | | | | flush() to check for UPDATE against partially NULL PK within one table to only actually happen if there's really an UPDATE to occur. [ticket:2390]
* declarative reflection exampleMike Bayer2012-01-281-1/+34
|
* - [feature] New reflection feature "autoload_replace";Mike Bayer2012-01-283-54/+76
| | | | | | | | | | | | | | | when set to False on Table, the Table can be autoloaded without existing columns being replaced. Allows more flexible chains of Table construction/reflection to be constructed, including that it helps with combining Declarative with table reflection. See the new example on the wiki. [ticket:2356] - [bug] Improved the API for add_column() such that if the same column is added to its own table, an error is not raised and the constraints don't get doubled up. Also helps with some reflection/declarative patterns. [ticket:2356]
* fix a few py3k bugsMike Bayer2012-01-281-0/+1
|
* then merge thisMike Bayer2012-01-287-21/+38
|\
| * - [feature] Dialect-specific compilers now raiseMike Bayer2012-01-287-21/+38
| | | | | | | | | | | | | | | | CompileException for all type/statement compilation issues, instead of InvalidRequestError or ArgumentError. The DDL for CREATE TABLE will re-raise CompileExceptions to include table/column information for the problematic column. [ticket:2361]
* | - [bug] removed an erroneous "raise" in theMike Bayer2012-01-281-3/+0
|/ | | | | | | | SQLite dialect when getting table names and view names, where logic is in place to fall back to an older version of SQLite that doesn't have the "sqlite_temp_master" table.
* - [bug] Fixed bug where "merge" cascade couldMike Bayer2012-01-281-1/+4
| | | | | | | mis-interpret an unloaded attribute, if the load_on_pending flag were used with relationship(). Thanks to Kent Bower for tests. [ticket:2374]
* - [bug] Fixed bug in "mock" strategy wherebyMike Bayer2012-01-281-3/+3
| | | | | | correct DDL visit method wasn't called, resulting in "CREATE/DROP SEQUENCE" statements being duplicated [ticket:2384]
* - [bug] Fixed issue where the "required" exceptionMike Bayer2012-01-281-11/+22
| | | | | | would not be raised for bindparam() with required=True, if the statement were given no parameters at all. [ticket:2381]
* - [bug] Fixed bug where unpickled object didn'tMike Bayer2012-01-281-0/+4
| | | | | | | | have enough of its state set up to work correctly within the unpickle() event established by the mutable object extension, if the object needed ORM attribute access within __eq__() or similar. [ticket:2362]
* - [bug] Raise an exception if xyzload_all() isMike Bayer2012-01-281-2/+5
| | | | | used inappropriately with two non-connected relationships. [ticket:2370]
* - [bug] Fixed regression from 0.7.4 wherebyMike Bayer2012-01-281-1/+1
| | | | | | using an already instrumented column from a superclass as "polymorphic_on" failed to resolve the underlying Column. [ticket:2345]
* - [bug] Added a boolean check for the "finalize"Mike Bayer2012-01-271-1/+1
| | | | | | | | | function within the pool connection proxy's weakref callback before calling it, so that a warning isn't emitted that this function is None when the application is exiting and gc has removed the function from the module before the weakref callback was invoked. [ticket:2383]
* - [bug] Changed LRUCache, used by the mapperMike Bayer2012-01-271-4/+9
| | | | | | | | | to cache INSERT/UPDATE/DELETE statements, to use an incrementing counter instead of a timestamp to track entries, for greater reliability versus using time.time(), which can cause test failures on some platforms. [ticket:2379]
* - [bug] implemented standard "can't set attribute" /Mike Bayer2012-01-271-0/+4
| | | | | | "can't delete attribute" AttributeError when setattr/delattr used on a hybrid that doesn't define fset or fdel. [ticket:2353]
* - [bug] Fixed issue where modified session stateMike Bayer2012-01-271-4/+18
| | | | | | | | | | | | | | established after a failed flush would be committed as part of the subsequent transaction that begins automatically after manual call to rollback(). The state of the session is checked within rollback(), and if new state is present, a warning is emitted and restore_snapshot() is called a second time, discarding those changes. [ticket:2389] - repaired testing.assert_warnings to also verify that any warnings were emitted
* - [bug] Added ORA-03135 to the never endingMike Bayer2012-01-251-1/+3
| | | | | list of oracle "connection lost" errors [ticket:2388]
* o null check PyObject_Repr resultsPhilip Jenvey2012-01-232-7/+20
| | | | o limit size of strings passed to PyErr_Format
* don't need to use __builtin__ for these things, doesn't work in py3kMike Bayer2012-01-231-8/+5
|
* 2.4 doesn't have any()Mike Bayer2012-01-222-1/+11
|
* - [feature] Added new capability to relationshipMike Bayer2012-01-224-2/+29
| | | | | | | | | | | loader options to allow "default" loader strategies. Pass '*' to any of joinedload(), lazyload(), subqueryload(), or noload() and that becomes the loader strategy used for all relationships, except for those explicitly stated in the Query. Thanks to up-and-coming contributor Kent Bower for an exhaustive and well written test suite ! [ticket:2351]
* - [bug] Dropped the "30 char" limit on pymssql,Mike Bayer2012-01-221-1/+0
| | | | | | | | | based on reports that it's doing things better these days. pymssql hasn't been well tested and as the DBAPI is in flux it's still not clear what the status is on this driver and how SQLAlchemy's implementation should adapt. [ticket:2347]
* - [bug] Adjusted the regexp used in theMike Bayer2012-01-221-1/+1
| | | | | | | | | | mssql.TIME type to ensure only six digits are received for the "microseconds" portion of the value, which is expected by Python's datetime.time(). Note that support for sending microseconds doesn't seem to be possible yet with pyodbc at least. [ticket:2340]
* - adjust the test for [ticket:2377] to be less controversial onMike Bayer2012-01-221-11/+14
| | | | | | problematic backends like Oracle.i - move the check generated in r85017c4310d2 up for both label name/name comparisions, fixes additional mismatches which can occur
* fix a callcount issue hereMike Bayer2012-01-221-3/+1
|
* couple more vars not needed outsideMike Bayer2012-01-221-4/+2
|
* - apply the pyflakes stick to strategies.py. In particular, tryMike Bayer2012-01-221-194/+285
| | | | | | | | | | | | to get almost every method to be less than 50 lines. For the relationship loaders this meant finding some decent boundaries to split things up. I find this style a bit unnatural as in some cases we are just doing three things with a handful of variables, why shuffle them between three methods that are entirely dependent on each other, but not sure what other option there is for a long list of steps like subquery loading. Also renamed all the "loader callables" to something descriptive, might help when they come up in stack traces.
* - [bug] Fixed bug whereby a table-bound ColumnMike Bayer2012-01-224-11/+41
| | | | | | | | | | | object named "<a>_<b>" which matched a column labeled as "<tablename>_<colname>" could match inappropriately when targeting in a result set row. [ticket:2377] - requires that we change the tuple format in RowProxy. Makes an improvement to the cases tested against an unpickled RowProxy as well though doesn't solve the problem there entirely.
* - [bug] Improved error messages when a non-stringMike Bayer2012-01-222-31/+79
| | | | | | | | | or invalid string is passed to any of the date/time processors used by SQLite, including C and Python versions. [ticket:2382] - changed the import model of processors.py so that we can get at the pure python versions and C versions simultaneously in tests.
* - [feature] Added "false()" and "true()" expressionMike Bayer2012-01-182-0/+8
| | | | | | | constructs to sqlalchemy.sql namespace, though not part of __all__ as of yet. - [bug] sql.false() and sql.true() compile to 0 and 1, respectively in sqlite [ticket:2368]
* - [bug] fixed regexp that filters out warningsMike Bayer2012-01-171-3/+1
| | | | | for non-reflected "PARTITION" directives, thanks to George Reilly [ticket:2376]
* another serializable for [ticket:2371]Mike Bayer2012-01-121-2/+9
|
* - [bug] ensure pickleability of all ORM exceptionsMike Bayer2012-01-111-5/+12
| | | | for multiprocessing compatibility. [ticket:2371]
* further fixes for column/table errorsMike Bayer2012-01-111-0/+7
|
* some adjustments for py3kMike Bayer2012-01-111-1/+1
|
* add examples for multi metadata under __abstract__, custom vertical partitioningMike Bayer2012-01-111-0/+21
|
* - Fixed regression from 0.6 whereby ifMike Bayer2012-01-103-14/+18
| | | | | | | "load_on_pending" relationship() flag were used where a non-"get()" lazy clause needed to be emitted on a pending object, it would fail to load.
* - [bug] Added __reduce__ to StatementError,Mike Bayer2012-01-101-0/+8
| | | | | | | DBAPIError so that exceptions are pickleable, as when using multiprocessing. However, not all DBAPIs support this yet, such as psycopg2. [ticket:2371]
* sqlsoup is released separatelyMike Bayer2012-01-081-2/+9
|
* fix small update doc issue [ticket:2158]Mike Bayer2012-01-081-1/+1
|
* that's not a "name=0", that's a counter. so name is None unconditonally.Mike Bayer2012-01-071-6/+4
| | | | [ticket:2348]
* - [bug] the "name" of an FK constraint in SQLiteMike Bayer2012-01-071-0/+2
| | | | | | is reflected as "None", not "0" [ticket:2364]. SQLite does not appear to support constraint naming in any case (the names are ignored).