/search.css" rel="stylesheet" type="text/css"/> /search.js">
| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

In This Package:

Public Member Functions | Public Attributes | Static Private Attributes
count::Count Class Reference

List of all members.

Public Member Functions

def __init__
def __call__

Public Attributes

 tab
 nvld
 npay
 nmet

Static Private Attributes

string _nvld = "select count(*) as nvld from %(tab)sVld"
string _npay = "select count(*) as npay from %(tab)s"
string _nmet = "select LASTUSEDSEQNO from LOCALSEQNO as nmet where TABLENAME='%(tab)s'"

Detailed Description

Simply counts validity and payload entries and the metadata LASTUSEDSEQNO from LOCALSEQNO table

Definition at line 9 of file count.py.


Constructor & Destructor Documentation

def count::Count::__init__ (   self,
  tab 
)

Definition at line 17 of file count.py.

00018                            :
00019         dict.__init__(self)
00020         self.tab = tab
00021         self.nvld = self._nvld % locals() 
00022         self.npay = self._npay % locals() 
00023         self.nmet = self._nmet % locals() 


Member Function Documentation

def count::Count::__call__ (   self,
  db,
  checkpoint = None 
)
Perform mysql queries that mostly return single integers 
and persist results.

:param db: `DB` instance
:param checkpoint: path to file to persist query results in   

Definition at line 24 of file count.py.

00025                                            :
00026         """
00027         Perform mysql queries that mostly return single integers 
00028         and persist results.
00029 
00030         :param db: `DB` instance
00031         :param checkpoint: path to file to persist query results in   
00032         """
00033         self.clear()
00034         self['tab'] = self.tab 
00035         for sql in [self.nvld, self.npay,self.nmet]:
00036             r = db(sql)
00037             if len(r) == 1:
00038                 self.update(r[0])
00039             else:
00040                 pass
00041         if checkpoint:
00042             Pickler.checkpoint(dict(self), checkpoint)
00043 


Member Data Documentation

string count::Count::_nvld = "select count(*) as nvld from %(tab)sVld" [static, private]

Definition at line 13 of file count.py.

string count::Count::_npay = "select count(*) as npay from %(tab)s" [static, private]

Definition at line 14 of file count.py.

string count::Count::_nmet = "select LASTUSEDSEQNO from LOCALSEQNO as nmet where TABLENAME='%(tab)s'" [static, private]

Definition at line 15 of file count.py.

Definition at line 17 of file count.py.

Definition at line 17 of file count.py.

Definition at line 17 of file count.py.

Definition at line 17 of file count.py.


The documentation for this class was generated from the following file:
| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

Generated on Fri May 16 2014 09:57:24 for DybDbi by doxygen 1.7.4