Commit Graph

1583 Commits

Author SHA1 Message Date
Mike Bayer 8a3cfd2ddd removed lockmode from get_by 2006-09-11 03:17:25 +00:00
Mike Bayer 5157ce1658 sqlite doesnt support FOR UPDATE 2006-09-11 00:23:48 +00:00
Mike Bayer 13aa802836 ConcurrentModificationExecption 2006-09-11 00:23:31 +00:00
Mike Bayer 9cc0aa292c - implemented "version check" logic in Query/Mapper, used
when version_id_col is in effect and query.with_lockmode()
is used to get() an instance thats already loaded
[ticket:292]
2006-09-11 00:20:28 +00:00
Mike Bayer d8bdde94cb checks for invalid lockmode argument 2006-09-10 23:59:30 +00:00
Mike Bayer 47d8b03b14 - changed "for_update" parameter to accept False/True/"nowait"
and "read", the latter two of which are interpreted only by
Oracle and Mysql [ticket:292]
- added "lockmode" argument to base Query select/get functions,
including "with_lockmode" function to get a Query copy that has
a default locking mode.  Will translate "read"/"update"
arguments into a for_update argument on the select side.
[ticket:292]
2006-09-10 23:52:04 +00:00
Mike Bayer 287bf21795 removed auto-dispose on __del__, produces too much garbage exceptiongs 2006-09-10 20:13:46 +00:00
Mike Bayer eed944dbb9 fixup to printing of uow 2006-09-07 23:04:13 +00:00
Mike Bayer 45dd486e06 - more rearrangements of unit-of-work commit scheme to better allow
dependencies within circular flushes to work properly...updated
task traversal/logging implementation

this work is still under construction !  requires more unit tests and
new dumper needs to be finished.
2006-09-07 20:04:10 +00:00
Mike Bayer 8f43b24f32 forgot the tearDown step.... 2006-09-07 17:14:11 +00:00
Mike Bayer d5d3c5495d fixed constructor on bigint 2006-09-06 01:00:06 +00:00
Mike Bayer e504454a4c added link 2006-09-05 18:42:43 +00:00
Mike Bayer f2d050180a 0.2.8.. rel_0_2_8 2006-09-05 17:19:26 +00:00
Mike Bayer 9a52478189 - added basic 'zblog' test suite
- better error message for mapper orphan detect
2006-09-05 17:16:26 +00:00
Mike Bayer 20f15720da restored "optimistic" behavior of hasparent. its generally disastrous without that flag as its impossible to load all lazy loaders, deal with attributes that "noload", etc. just to check for orphan status. 2006-09-05 16:58:02 +00:00
Mike Bayer f3d72a7187 - unicode fix for startswith()/endswith() [ticket:296] 2006-09-05 15:39:59 +00:00
Mike Bayer 5bcb6e786f update 2006-09-04 23:55:38 +00:00
Mike Bayer 189f015c2a further fixes to case sensitive logic 2006-09-04 23:05:36 +00:00
Mike Bayer 3a4f96e070 revised section on quoting, semanticized headings and table of content lists 2006-09-04 23:02:13 +00:00
Mike Bayer 9deaebf93c - import of py2.5s sqlite3 [ticket:293] 2006-09-04 02:22:00 +00:00
Mike Bayer f5454c89ea simplification to quoting to just cache strings per-dialect, added quoting for alias and label names
fixes [ticket:294]
2006-09-04 01:56:31 +00:00
Mike Bayer c0d89919ec cleanup/unit test fixes 2006-09-03 02:46:46 +00:00
Mike Bayer fe0a1aa7fa - further changes to attributes with regards to "trackparent". the "commit" operation
now sets a "hasparent" flag for all attributes to all objects.  that way lazy loads
via callables get included in trackparent, and eager loads do as well because the mapper
calls commit() on all objects at load time.  this is a less shaky method than the "optimistic"
thing in the previous commit, but uses more memory and involves more overhead.
- some tweaks/cleanup to unit tests
2006-09-02 04:00:44 +00:00
Mike Bayer 35e2f6680b futher fix to the "orphan state" idea. to avoid setting tons of
"hasparent" flags on objects as they are loaded, both from lazy and eager loads,
the "orphan" check now uses an "optimistic" flag to determine the result if no
"hasparent" flag is found for a particular relationship on an instance. if the
instance has an _instance_key and therefore was loaded from the database, it is
assumed to not be an orphan unless a "False" hasparent flag has been set.  if the
instance does not have an _instance_key and is therefore transient/pending, it is
assumed to be an orphan unless a "True" hasparent flag has been set.
2006-09-01 17:01:55 +00:00
Mike Bayer 005603e2fb insure that "parent" pointers are set up on objects that were lazily loaded 2006-09-01 16:25:20 +00:00
Mike Bayer 2c1006534e possible fix for [ticket:276]. if mysql detects case-insensitivity, converts
tables to lower case names
2006-09-01 00:30:36 +00:00
Mike Bayer a0255d22d0 since casing is figured out quasi-automatically when creating table/column/etc,
removed casing checks within pg reflection
2006-08-31 23:58:34 +00:00
Mike Bayer 165065a948 quoting more or less working with oracle 2006-08-31 23:55:42 +00:00
Mike Bayer 9f23a5c3de fix to from clause in unittest query...somehow this didnt fail on pg 8.0, but fails on 8.1 2006-08-31 23:41:49 +00:00
Mike Bayer 7d39ad95d8 defaults and constraints have optional parent 2006-08-31 23:39:42 +00:00
Mike Bayer 7b82393355 sequence/default adjustments to allow postgres 8.1 tests to function 2006-08-31 23:33:55 +00:00
Mike Bayer b02b64675e pg formats sequence name, more quote test fixes 2006-08-31 23:26:30 +00:00
Mike Bayer e168ef63a9 some tweaks to oracle casing... 2006-08-31 23:13:14 +00:00
Mike Bayer 0c7250a474 - added case_sensitive argument to MetaData, Table, Column, determines
itself automatically based on if a parent schemaitem has a non-None
setting for the flag, or if not, then whether the identifier name is all lower
case or not.  when set to True, quoting is applied to identifiers with mixed or
uppercase identifiers.  quoting is also applied automatically in all cases to
identifiers that are known to be reserved words or contain other non-standard
characters. various database dialects can override all of this behavior, but
currently they are all using the default behavior.  tested with postgres, mysql,
sqlite.  needs more testing with firebird, oracle, ms-sql. part of the ongoing
work with [ticket:155]
2006-08-31 18:58:22 +00:00
Mike Bayer 2e077dc627 - deregister Table from MetaData when autoload fails; [ticket:289] 2006-08-28 16:55:22 +00:00
Mike Bayer 7252ccd7c9 - fix to using query.count() with distinct, **kwargs with SelectResults
count() [ticket:287]
2006-08-27 21:22:28 +00:00
Mike Bayer 47332cb147 - changed "invalidate" semantics with pooled connection; will
instruct the underlying connection record to reconnect the next
time its called.  "invalidate" will also automatically be called
if any error is thrown in the underlying call to connection.cursor().
this will hopefully allow the connection pool to reconnect to a
database that had been stopped and started without restarting
the connecting application [ticket:121]
2006-08-26 21:32:11 +00:00
Mike Bayer 3188bd0567 [ticket:266] constraint name in PrimaryKeyConstraint 2006-08-26 20:22:48 +00:00
Mike Bayer ad8b3c63e0 doc bug [ticket:278] 2006-08-26 20:16:19 +00:00
Mike Bayer 2d4dfb959b - added "timezone=True" flag to DateTime and Time types. postgres
so far will convert this to "TIME[STAMP] (WITH|WITHOUT) TIME ZONE",
so that control over timezone presence is more controllable (psycopg2
returns datetimes with tzinfo's if available, which can create confusion
against datetimes that dont).
[ticket:275]
2006-08-26 19:46:33 +00:00
Mike Bayer 5b8ab3e8ab added "dev" tag to default setup
some extra README
2006-08-26 19:00:37 +00:00
Mike Bayer 7a15313c9e fixed inaccuracies regarding "connectable" parameter sent to create/drop 2006-08-26 18:55:05 +00:00
Mike Bayer 5385cc32c7 TODO for oracle 2006-08-26 16:16:11 +00:00
Mike Bayer 23e3420fc9 added limit/offset to union queries 2006-08-26 14:42:18 +00:00
Mike Bayer 8260ca2723 - cleanup on connection methods + documentation. custom DBAPI
arguments specified in query string, 'connect_args' argument
to 'create_engine', or custom creation function via 'creator'
function to 'create_engine'.
- added "recycle" argument to Pool, is "pool_recycle" on create_engine,
defaults to 3600 seconds; connections after this age will be closed and
replaced with a new one, to handle db's that automatically close
stale connections [ticket:274]
2006-08-25 16:27:10 +00:00
Mike Bayer 367e3b61a1 [ticket:282] 2006-08-23 01:31:37 +00:00
Mike Bayer f62e5a56e8 the "check for orphans" step will cascade the delete operation to child objects. 2006-08-22 22:52:12 +00:00
Mike Bayer a8d1aecfab - urls support escaped characters in passwords [ticket:281] 2006-08-22 18:58:01 +00:00
Mike Bayer 3003239beb sqlite dialects can be created without pysqlite installed 2006-08-21 20:10:56 +00:00
Mike Bayer 43d3b77307 - unit tests updated to run without any pysqlite installed; pool
test uses a mock DBAPI
2006-08-21 20:01:32 +00:00