Support new security model in the formSubmit function - bug fix
[openemr.git] / library / adodb / perf / perf-informix.inc.php
blobd897ea40e946e1846d3eb4cd07d76494cb8b592e
1 <?php
2 /*
3 V5.14 8 Sept 2011 (c) 2000-2011 John Lim (jlim#natsoft.com). All rights reserved.
4 Released under both BSD license and Lesser GPL library license.
5 Whenever there is any discrepancy between the two licenses,
6 the BSD license will take precedence. See License.txt.
7 Set tabs to 4 for best viewing.
9 Latest version is available at http://adodb.sourceforge.net
11 Library for basic performance monitoring and tuning
15 // security - hide paths
16 if (!defined('ADODB_DIR')) die();
19 // Thx to Fernando Ortiz, mailto:fortiz#lacorona.com.mx
20 // With info taken from http://www.oninit.com/oninit/sysmaster/index.html
22 class perf_informix extends adodb_perf{
24 // Maximum size on varchar upto 9.30 255 chars
25 // better truncate varchar to 255 than char(4000) ?
26 var $createTableSQL = "CREATE TABLE adodb_logsql (
27 created datetime year to second NOT NULL,
28 sql0 varchar(250) NOT NULL,
29 sql1 varchar(255) NOT NULL,
30 params varchar(255) NOT NULL,
31 tracer varchar(255) NOT NULL,
32 timer decimal(16,6) NOT NULL
33 )";
35 var $tablesSQL = "select a.tabname tablename, ti_nptotal*2 size_in_k, ti_nextns extents, ti_nrows records from systables c, sysmaster:systabnames a, sysmaster:systabinfo b where c.tabname not matches 'sys*' and c.partnum = a.partnum and c.partnum = b.ti_partnum";
37 var $settings = array(
38 'Ratios',
39 'data cache hit ratio' => array('RATIOH',
40 "select round((1-(wt.value / (rd.value + wr.value)))*100,2)
41 from sysmaster:sysprofile wr, sysmaster:sysprofile rd, sysmaster:sysprofile wt
42 where rd.name = 'pagreads' and
43 wr.name = 'pagwrites' and
44 wt.name = 'buffwts'",
45 '=WarnCacheRatio'),
46 'IO',
47 'data reads' => array('IO',
48 "select value from sysmaster:sysprofile where name='pagreads'",
49 'Page reads'),
51 'data writes' => array('IO',
52 "select value from sysmaster:sysprofile where name='pagwrites'",
53 'Page writes'),
55 'Connections',
56 'current connections' => array('SESS',
57 'select count(*) from sysmaster:syssessions',
58 'Number of sessions'),
60 false
64 function perf_informix(&$conn)
66 $this->conn = $conn;