summaryrefslogtreecommitdiff
path: root/test/sql/test_defaults.py
diff options
context:
space:
mode:
authorMike Bayer <mike_mp@zzzcomputing.com>2015-03-07 12:48:13 -0500
committerMike Bayer <mike_mp@zzzcomputing.com>2015-03-07 17:18:31 -0500
commitb3d3795de0d45fe4adda7393881f0f955409a45d (patch)
treee1ed366f07f596388cfca024ae20128131565f61 /test/sql/test_defaults.py
parent0a1f720355f02d38da2a5a8444712dd7d199c713 (diff)
downloadsqlalchemy-positional_targeting.tar.gz
- The SQL compiler now generates the mapping of expected columnspositional_targeting
such that they are matched to the received result set positionally, rather than by name. Originally, this was seen as a way to handle cases where we had columns returned with difficult-to-predict names, though in modern use that issue has been overcome by anonymous labeling. In this version, the approach basically reduces function call count per-result by a few dozen calls, or more for larger sets of result columns. The approach still degrades into a modern version of the old approach if textual elements modify the result map, or if any discrepancy in size exists between the compiled set of columns versus what was received, so there's no issue for partially or fully textual compilation scenarios where these lists might not line up. fixes #918 - callcounts still need to be adjusted down for this so zoomark tests won't pass at the moment
Diffstat (limited to 'test/sql/test_defaults.py')
-rw-r--r--test/sql/test_defaults.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/sql/test_defaults.py b/test/sql/test_defaults.py
index ecf3dcc4d..c154daa22 100644
--- a/test/sql/test_defaults.py
+++ b/test/sql/test_defaults.py
@@ -133,7 +133,7 @@ class DefaultTest(fixtures.TestBase):
[
func.trunc(
func.sysdate(), sa.literal_column("'DAY'"),
- type_=sa.Date).label('today')]))
+ type_=sa.Date)]))
assert isinstance(ts, datetime.date) and not isinstance(
ts, datetime.datetime)
f = sa.select([func.length('abcdef')], bind=db).scalar()