Overview

Namespaces

  • cli_db
    • propel
      • map
      • om
  • cli_import
  • LoggedPDO
  • None
  • PHP
  • webservices
    • cart
    • combisearch
    • details
      • annotations
        • feature
    • graphs
      • barplot
      • genome
    • listing
    • queue

Classes

  • Features
  • Isoform
  • Statistical_information
  • Unigene
  • Overview
  • Namespace
  • Class
  • Tree
 1: <?php
 2: 
 3: namespace webservices\details;
 4: 
 5: use \PDO as PDO;
 6: /**
 7:  * WebService.
 8:  * Returns statistical information on given release.
 9:  * called /ajax/details/statistical_information/&lt;organism&gt;/&lt;release&gt;
10:  */
11: class Statistical_information extends \WebService {
12: 
13:     public function execute($querydata) {
14:         global $db;
15:         
16:         $organism = $querydata['query1'];
17:         $release = $querydata['query2'];
18: 
19: 
20: #UI hint
21:         if (false)
22:             $db = new PDO();
23: 
24:         $query_get_stats = <<<EOF
25: SELECT *
26: FROM materialized_view_statistical_information
27: WHERE
28:    organism = ?
29:    AND release=?
30: EOF;
31: 
32:         $stm_get_stats = $db->prepare($query_get_stats);
33: 
34:         $data = array('results' => array());
35: 
36:         $stm_get_stats->execute(array($organism, $release));
37:         while ($row = $stm_get_stats->fetch(PDO::FETCH_ASSOC)) {
38:             $data['results'] = $row;
39:         }
40: 
41:         return $data;
42:     }
43: 
44: }
45: 
46: ?>
47: 
tbro API documentation generated by ApiGen 2.8.0