Mike Bayer
8a865a4d1f
Fixed bug whereby joining a select() of a table "A" with multiple
...
foreign key paths to a table "B", to that table "B", would fail
to produce the "ambiguous join condition" error that would be
reported if you join table "A" directly to "B"; it would instead
produce a join condition with multiple criteria.
[ticket:2738]
2013-06-03 17:03:15 -04:00
Mike Bayer
d993bdeac8
- remove the `__iter__()` with notimplemented since it interferes
...
with legitimate iterable detection, [ticket:2726]
2013-06-03 16:32:12 -04:00
Mike Bayer
f2328d6df4
test tweak
2013-06-03 13:45:28 -04:00
Mike Bayer
74c98bf182
Merge branch 'master' into ticket_1068
2013-06-03 13:13:16 -04:00
Mike Bayer
c2a158c137
- some tweaks to try to help out mssql+pyodbc support a bit, py3k is really
...
not happening too well (I need to stick with linux + freetds 0.91, I know)
2013-06-03 12:54:56 -04:00
Mike Bayer
ff399ac750
magic accessors to the rescue
2013-05-27 21:43:29 -04:00
Mike Bayer
0adcfea0d3
still not locating more nested expressions, may need to match on name
2013-05-27 21:05:16 -04:00
Mike Bayer
a9ed16f80d
attempt number one, doesn't detect though if the label in the order by is not directly present there.
2013-05-27 19:22:59 -04:00
Mike Bayer
2ddcd20267
Merge branch 'master' into rel_0_9
2013-05-26 17:18:27 -04:00
Mike Bayer
e2b8c893ca
fix this test
2013-05-26 17:18:04 -04:00
Mike Bayer
cca97433c1
merge default
2013-05-05 01:42:26 -04:00
Mike Bayer
c7ce62cf65
- OK we have -w sql passing for: sqlite, postgresql, oursql 2.7 + 3.3, mysqldb 2.7
2013-05-04 15:26:28 -04:00
Mike Bayer
afcbd7419c
and int types here...
2013-05-04 15:10:41 -04:00
Mike Bayer
2a8fcfaa42
update test
2013-05-04 15:09:04 -04:00
Mike Bayer
ee9723d7d7
cleanup
2013-05-04 15:08:08 -04:00
Mike Bayer
9db36c36aa
cleanup and formatting
2013-05-04 15:06:47 -04:00
Mike Bayer
2a99b770dd
- unicode literals need to just be handled differently if they have utf-8
...
encoded in them vs. unicode escaping. not worth figuring out how to combine
these right now
2013-05-04 14:59:26 -04:00
Mike Bayer
e9ea5acc51
formatting stuff
2013-05-04 14:23:29 -04:00
Mike Bayer
8f9b7ad31f
formatting stuff
2013-05-04 14:23:29 -04:00
Mike Bayer
fc624dcfa4
- test_types, test_compiler, with sqlite at least
2013-04-28 14:44:21 -04:00
Mike Bayer
4b614b9b35
- the raw 2to3 run
...
- went through examples/ and cleaned out excess list() calls
2013-04-27 19:53:57 -04:00
Mike Bayer
5884c2e7e5
Fully implemented the IS and IS NOT operators with
...
regards to the True/False constants. An expression like
``col.is_(True)`` will now render ``col IS true``
on the target platform, rather than converting the True/
False constant to an integer bound parameter.
This allows the ``is_()`` operator to work on MySQL when
given True/False constants.
[ticket:2682]
2013-04-22 19:12:47 -04:00
Mike Bayer
23c744b54e
- Improvements to the operation of the pymysql dialect on
...
Python 3, including some important decode/bytes steps.
Issues remain with BLOB types due to driver issues.
Courtesy Ben Trofatter.
- start using util.py3k, we will eventually remove the
sa2to3 fixer entirely
2013-04-21 17:09:45 -04:00
Mike Bayer
d5af821b5d
Merged in bentrofatter/sqlalchemy-2663 (pull request #49 )
...
Fixed PyMySQL problems for Python 2.x and mitigated some issues with Python 3.x
2013-04-21 16:58:55 -04:00
Mike Bayer
a5ede47f12
A major fix to the way in which a select() object produces
...
labeled columns when apply_labels() is used; this mode
produces a SELECT where each column is labeled as in
<tablename>_<columnname>, to remove column name collisions
for a multiple table select. The fix is that if two labels
collide when combined with the table name, i.e.
"foo.bar_id" and "foo_bar.id", anonymous aliasing will be
applied to one of the dupes. This allows the ORM to handle
both columns independently; previously, 0.7
would in some cases silently emit a second SELECT for the
column that was "duped", and in 0.8 an ambiguous column error
would be emitted. The "keys" applied to the .c. collection
of the select() will also be deduped, so that the "column
being replaced" warning will no longer emit for any select()
that specifies use_labels, though the dupe key will be given
an anonymous label which isn't generally user-friendly.
[ticket:2702]
2013-04-11 16:14:23 -04:00
Mike Bayer
6bdd3bb93f
- reinstate insert returning back into test_insert.py; defaultdialect
...
needs to be explicit here since tablestest sticks testing.db onto metadata.bind
2013-04-01 15:41:57 -04:00
Diana Clarke
25c6732019
moving insert returning test back into CRUD test class until I figure out why moving it broke the oracle/postgres builds
2013-03-30 09:30:58 -04:00
Diana Clarke
2fa9dd6bb8
whitespace
2013-03-30 01:39:40 -04:00
Diana Clarke
2ffc925588
move the update tests from CRUDTest into sql/test_update.py (see #2630 )
2013-03-30 01:38:17 -04:00
Diana Clarke
e6d6cfbf6b
fixing tests for --db=mysql: VARCHAR requires a length on dialect mysql
2013-03-30 01:01:59 -04:00
Diana Clarke
192bddc720
starting on the update tests next, pep8 pass first (see #2630 )
2013-03-30 00:33:07 -04:00
Diana Clarke
17487a0db7
move the insert tests from CRUDTest into sql/test_insert.py (see #2630 )
2013-03-29 19:10:01 -04:00
Diana Clarke
0f203d57cd
move the delete tests from CRUDTest into sql/test_delete.py (see #2630 )
2013-03-29 17:25:39 -04:00
Mike Bayer
b5b751e3de
fix syntax error
2013-03-24 13:45:37 -04:00
Mike Bayer
35c5fd3fba
Fixed bug whereby a DBAPI that can return "0"
...
for cursor.lastrowid would not function correctly
in conjunction with :attr:`.ResultProxy.inserted_primary_key`.
2013-03-23 19:00:11 -04:00
Ben Trofatter
2830346207
Removed commented line from test_types.py
2013-03-19 09:29:26 -07:00
Ben Trofatter
68299cbd44
Added workaround for pymysql3 double wrapping ProgrammingErrors to pymysql dialect.
...
Added workaround for pymysql3 return a bytes object when queried for isolation level.
2013-03-18 17:58:41 -07:00
Mike Bayer
72c4bdf735
merge plus fix the test spelling too
2013-03-18 11:00:47 -07:00
Mike Bayer
6be35e3898
- auto-append for CheckConstraint should skip table if the expression is against
...
a lower-case-t table
2013-03-09 18:05:21 -05:00
Mike Bayer
c8a80e2130
- remove all compat items that are pre-2.5 (hooray)
...
- other cleanup
- don't need compat.decimal, that approach never panned out. hopefully
outside libs aren't pulling it in, they shouldn't be
2013-03-09 17:26:16 -05:00
Mike Bayer
8ef3ed1032
- this test is ridiculous, executemany() + returning not supported
2013-03-09 14:42:34 -05:00
Mike Bayer
a5ec70a961
- the base correlate tests in test_compiler cover the ones that were here
...
for now
- fix up adaptation tests to still try to exercise the correlation argument
2013-03-09 12:12:01 -05:00
Mike Bayer
d5d9a8c24e
- since correlation is now always at least semi-automatic, remove the
...
ability for correlation to have any effect for a SELECT that's stated
in the FROM.
- add a new exhaustive test suite for correlation to test_compiler
2013-03-09 11:46:44 -05:00
Mike Bayer
9793bf7fb2
go back to the original form, then break out this test into individuals
...
so it can be managed more easily
2013-03-08 19:00:13 -05:00
Luke Cyca
f122a307e0
Changed behavior of Select.correlate() to ignore correlations to froms that don't exist in the superquery.
2013-03-07 11:56:11 -08:00
Mike Bayer
a98bb5f0cd
Merged in nakagami/sqlalchemy/cymysql (pull request #42 )
...
cymysql support
2013-03-07 12:36:35 -05:00
Hajime Nakagami
50cc82b796
mysql+cymysql test_types.py
2013-03-06 00:21:54 +09:00
Mike Bayer
6ddfe3b390
- :meth:.MetaData.create_all and :meth:.MetaData.drop_all will
...
now accommodate an empty list as an instruction to not create/drop
any items, rather than ignoring the collection. [ticket:2664].
This is a behavioral change and extra notes to the changelog
and migration document have been added.
- create a new test suite for exercising codepaths
in engine/ddl.py
2013-03-02 17:47:58 -05:00
Mike Bayer
45ba7b6e0e
- some linter cleanup, though have disabled the newer linter rules which are just
...
too much for now
2013-03-02 16:37:58 -05:00
Hajime Nakagami
ddca4d30a1
not return unicode string in cymysql dialect
2013-03-02 02:13:05 +09:00