summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/sql/operators.py
Commit message (Collapse)AuthorAgeFilesLines
...
* - add full docs for like()/ilike()Mike Bayer2013-01-281-0/+28
|
* happy new year (see #2645)Diana Clarke2013-01-011-1/+1
|
* just a pep8 pass of lib/sqlalchemy/sql/Diana Clarke2012-11-191-5/+40
|
* Fixed a gotcha where inadvertently calling list() on aMike Bayer2012-11-181-0/+5
| | | | | | :class:`.ColumnElement` would go into an endless loop, if :meth:`.ColumnOperators.__getitem__` were implemented. A new NotImplementedError is emitted via ``__iter__()``.
* - more docsMike Bayer2012-10-261-6/+10
| | | | - it appears we can get rid of all those "XYZ_toplevel" names and use :doc:.
* Added :meth:`.ColumnOperators.notin_`,Mike Bayer2012-10-241-3/+48
| | | | | | :meth:`.ColumnOperators.notlike`, :meth:`.ColumnOperators.notilike` to :class:`.ColumnOperators`. [ticket:2580]
* - [bug] A tweak to column precedence which moves theMike Bayer2012-09-221-15/+20
| | | | | | | "concat" and "match" operators to be the same as that of "is", "like", and others; this helps with parenthesization rendering when used in conjunction with "IS". [ticket:2564]
* - [bug] Added missing operators is_(), isnot()Mike Bayer2012-09-221-0/+30
| | | | | | to the ColumnOperators base, so that these long-available operators are present as methods like all the other operators. [ticket:2544]
* `lshift` (<<) and `rshift` (>>) are also supported as optional operators.Mike Bayer2012-09-041-1/+19
|
* - [feature] Reworked the startswith(), endswith(),Mike Bayer2012-08-271-0/+9
| | | | | | | | | | | | contains() operators to do a better job with negation (NOT LIKE), and also to assemble them at compilation time so that their rendered SQL can be altered, such as in the case for Firebird STARTING WITH [ticket:2470] - [feature] firebird - The "startswith()" operator renders as "STARTING WITH", "~startswith()" renders as "NOT STARTING WITH", using FB's more efficient operator. [ticket:2470]
* - [feature] The Core oeprator system now includesMike Bayer2012-08-201-2/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | the `getitem` operator, i.e. the bracket operator in Python. This is used at first to provide index and slice behavior to the Postgresql ARRAY type, and also provides a hook for end-user definition of custom __getitem__ schemes which can be applied at the type level as well as within ORM-level custom operator schemes. Note that this change has the effect that descriptor-based __getitem__ schemes used by the ORM in conjunction with synonym() or other "descriptor-wrapped" schemes will need to start using a custom comparator in order to maintain this behavior. - [feature] postgresql.ARRAY now supports indexing and slicing. The Python [] operator is available on all SQL expressions that are of type ARRAY; integer or simple slices can be passed. The slices can also be used on the assignment side in the SET clause of an UPDATE statement by passing them into Update.values(); see the docs for examples. - [feature] Added new "array literal" construct postgresql.array(). Basically a "tuple" that renders as ARRAY[1,2,3].
* - fix the labeled column with column_expression() issue, finishes [ticket:1534]Mike Bayer2012-08-181-5/+11
| | | | | | | | | | | - epic documentation sweep for new operator system, making ORM links consistent and complete, full documentation and examples for type/SQL expression feature - type_coerce() explicitly accepts BindParamClause objects - change UserDefinedType to coerce the other side to itself by default as this is much more likely what's desired - make coerce_compared_type() fully public on all types - have profiling run the test no matter what so that the test_zoomarks don't fail when callcounts are missing
* docs for custom ops...Mike Bayer2012-08-161-0/+17
|
* - hashableMike Bayer2012-08-131-0/+3
|
* - develop new system of applying custom operators to ColumnElement classes. ↵Mike Bayer2012-08-131-0/+4
| | | | | | resembles that of the ORM so far.
* some doc fixesMike Bayer2012-07-221-6/+7
|
* - [feature] Revised the rules used to determineMike Bayer2012-07-221-101/+129
| | | | | | | | | | | | the operator precedence for the user-defined operator, i.e. that granted using the ``op()`` method. Previously, the smallest precedence was applied in all cases, now the default precedence is zero, lower than all operators except "comma" (such as, used in the argument list of a ``func`` call) and "AS", and is also customizable via the "precedence" argument on the ``op()`` method. [ticket:2537]
* absolute imports in core, sqlMike Bayer2012-06-231-1/+1
|
* - [bug] Fixed bug in relationship comparisonsMike Bayer2012-04-251-3/+3
| | | | | | | whereby calling unimplemented methods like SomeClass.somerelationship.like() would produce a recursion overflow, instead of NotImplementedError.
* simplify remote annotation significantly, and alsoMike Bayer2012-02-081-0/+5
| | | | catch the actual remote columns more accurately.
* happy new yearMike Bayer2012-01-041-1/+1
|
* - Cls.column.collate("some collation") nowMike Bayer2011-10-231-6/+6
| | | | works. [ticket:1776] Also in 0.6.9
* - Fixed subtle bug that caused SQL to blowMike Bayer2011-06-271-0/+4
| | | | | | | up if: column_property() against subquery + joinedload + LIMIT + order by the column property() occurred. [ticket:2188]. Also in 0.6.9
* - move Operators and ColumnOperators into sqlalchemy.sql.operators - since thisMike Bayer2011-05-281-0/+424
| | | | | is strictly a system of routing Python operators into functions. Keep the references available in expression.py for the near future.
* - whitespace removal bonanzaMike Bayer2011-01-021-2/+2
|
* - clean up copyright, update for 2011, stamp every file withMike Bayer2011-01-021-0/+6
| | | | | a consistent tag - AUTHORS file
* Added NULLS FIRST and NULLS LAST support.Michael Trier2010-12-191-0/+6
| | | | | It's implemented as an extension to the asc() and desc() operators, called nullsfirst() and nullslast(). [ticket:723]
* - merge default tipMike Bayer2010-12-051-2/+9
|\
| * - Fixed operator precedence rules for multipleMike Bayer2010-11-251-1/+8
| | | | | | | | | | | | | | | | | | | | | | | | chains of a single non-associative operator. I.e. "x - (y - z)" will compile as "x - (y - z)" and not "x - y - z". Also works with labels, i.e. "x - (y - z).label('foo')" [ticket:1984] - Single element tuple expressions inside an IN clause parenthesize correctly, also from [ticket:1984], added tests for PG - re-fix again importlater, [ticket:1983]
* | - adapt initial patch from [ticket:1917] to current tipMike Bayer2010-11-161-1/+1
|/ | | | - raise TypeError for immutability
* - Added math negation operator support, -x.Mike Bayer2010-02-051-1/+2
|
* merge 0.6 series to trunk.Mike Bayer2009-08-061-1/+9
|
* - _CalculatedClause is goneMike Bayer2009-01-281-1/+1
| | | | | | | | - Function rolls the various standalone execution functionality of CC into itself, accesses its internal state more directly - collate just uses _BinaryExpression, don't know why it didn't do this already - added new _Case construct, compiles directly - the world is a happier place
* - Moved to 2.4+ import syntax (w/ some experimental merge-friendly formatting)Jason Kirtland2008-07-151-33/+36
|
* - Removed 2.3 set emulations/enhancements.Jason Kirtland2008-07-151-2/+2
| | | | (sets.Set-based collections & DB-API returns still work.)
* Added new basic match() operator that performs a full-text search. Supported ↵Michael Trier2008-07-131-0/+4
| | | | on PostgreSQL, SQLite, MySQL, MS-SQL, and Oracle backends.
* r4695 merged to trunk; trunk now becomes 0.5.Mike Bayer2008-05-091-1/+1
| | | | 0.4 development continues at /sqlalchemy/branches/rel_0_4
* - Support for COLLATE: collate(expr, col) and expr.collate(col)Jason Kirtland2008-04-161-0/+4
|
* added escape kw arg to contains(), startswith(), endswith(), [ticket:791]Mike Bayer2008-03-191-6/+6
|
* - like() and ilike() take an optional keyword argumentMike Bayer2008-03-191-6/+6
| | | | | | "escape=<somestring>", which is set as the escape character using the syntax "x LIKE y ESCAPE '<somestring>'" [ticket:993]
* - Converted MAGICCOOKIE=object() to a little symbol implementation to ease ↵Jason Kirtland2008-02-221-5/+4
| | | | object inspection and debugging
* a little pre-lunch decrufting and cleanupMike Bayer2007-12-181-0/+46
|
* - added op() operator to instrumented attributes; i.e.Mike Bayer2007-11-181-0/+3
| | | | User.name.op('ilike')('%somename%') [ticket:767]
* - Added contains operator (which generate a "LIKE %<other>%" clause).Gaëtan de Menten2007-10-191-0/+3
| | | | - Added test coverage for endswith operator
* Assorted unused imports from pyflakes, docstring tweaks, formatting.Jason Kirtland2007-10-131-3/+6
|
* Fixed signature for orm's BETWEEN operator.Jason Kirtland2007-08-271-2/+2
|
* 1. Module layout. sql.py and related move into a package called "sql".Mike Bayer2007-08-181-0/+61
2. compiler names changed to be less verbose, unused classes removed. 3. Methods on Dialect which return compilers, schema generators, identifier preparers have changed to direct class references, typically on the Dialect class itself or optionally as attributes on an individual Dialect instance if conditional behavior is needed. This takes away the need for Dialect subclasses to know how to instantiate these objects, and also reduces method overhead by one call for each one. 4. as a result of 3., some internal signatures have changed for things like compiler() (now statement_compiler()), preparer(), etc., mostly in that the dialect needs to be passed explicitly as the first argument (since they are just class references now). The compiler() method on Engine and Connection is now also named statement_compiler(), but as before does not take the dialect as an argument. 5. changed _process_row function on RowProxy to be a class reference, cuts out 50K method calls from insertspeed.py