Package orm2 :: Module sql :: Class where
[hide private]
[frames] | no frames]

Class where

source code

 _part --+    
         |    
    clause --+
             |
expression --+
             |
            where

Encapsulates the WHERE clause of a SELECT, UPDATE and DELETE statement. Just an expression with WHERE prepended.

Instance Methods [hide private]
  __sql__(self, runner)
  __add__(self, other)
Adding two where clauses connects them using AND (including parantheses)
  __mul__(self, other)
Multiplying two where clauses connects them using OR (including parantheses).

Inherited from _part: __eq__, __ne__, __str__

Inherited from expression: __init__

Inherited from expression (private): _append


Class Methods [hide private]
  or_(cls, others)
OTHERS is a list of sql.where instances that are connected using OR.
  and_(cls, others)
OTHERS is a list of sql.where instances that are connected using OR.

Class Variables [hide private]
  rank = 1

Method Details [hide private]

__sql__(self, runner)

source code 
None
Overrides: _part.__sql__

__add__(self, other)
(Addition operator)

source code 
Adding two where clauses connects them using AND (including parantheses)
Overrides: expression.__add__

__mul__(self, other)

source code 
Multiplying two where clauses connects them using OR (including parantheses).

or_(cls, others)
Class Method

source code 
OTHERS is a list of sql.where instances that are connected using OR.

and_(cls, others)
Class Method

source code 
OTHERS is a list of sql.where instances that are connected using OR.

Class Variable Details [hide private]

rank

None
Value:
1