12     public function __construct(&$oDB)
 
  17     public function status()
 
  19         if (!$this->oDB || PEAR::isError($this->oDB)) {
 
  20             throw new Exception('No database', 700);
 
  23         $sStandardWord = $this->oDB->getOne("SELECT make_standard_name('a')");
 
  24         if (PEAR::isError($sStandardWord)) {
 
  25             throw new Exception('Module failed', 701);
 
  28         if ($sStandardWord != 'a') {
 
  29             throw new Exception('Module call failed', 702);
 
  32         $sSQL = 'SELECT word_id, word_token, word, class, type, country_code, ';
 
  33         $sSQL .= "operator, search_name_count FROM word WHERE word_token IN (' a')";
 
  34         $iWordID = $this->oDB->getOne($sSQL);
 
  35         if (PEAR::isError($iWordID)) {
 
  36             throw new Exception('Query failed', 703);
 
  39             throw new Exception('No value', 704);
 
  43     public function dataDate()
 
  45         $sSQL = 'SELECT EXTRACT(EPOCH FROM lastimportdate) FROM import_status LIMIT 1';
 
  46         $iDataDateEpoch = $this->oDB->getOne($sSQL);
 
  48         if (PEAR::isError($iDataDateEpoch)) {
 
  49             throw Exception('Data date query failed '.$iDataDateEpoch->getMessage(), 705);
 
  52         return $iDataDateEpoch;