Advertisement
Guest User

Untitled

a guest
Feb 24th, 2014
108
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.84 KB | None | 0 0
  1.           query = table.select(table.id, where=Exists(                          
  2.                   subtable.select(subtable.id,                                  
  3.                       where=((table.id != subtable.id) &                        
  4.                           (table.account == subtable.account) &                  
  5.                           (table.party == subtable.party) &                      
  6.                           (((table.debit != zero) & (subtable.credit != zero))  
  7.                               | ((table.credit != zero) &                        
  8.                                   (subtable.credit != zero))) &                  
  9.                           (table.reconciliation == None) &                      
  10.                           (subtable.reconciliation == None))                    
  11.                       )))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement