]> CyberLeo.Net >> Repos - SourceForge/phpwiki.git/blob - lib/WikiDB/adodb/drivers/adodb-pdo_mssql.inc.php
Update adodb to adodb519
[SourceForge/phpwiki.git] / lib / WikiDB / adodb / drivers / adodb-pdo_mssql.inc.php
1 <?php
2
3
4 /*
5 V5.19  23-Apr-2014  (c) 2000-2014 John Lim (jlim#natsoft.com). All rights reserved.
6   Released under both BSD license and Lesser GPL library license.
7   Whenever there is any discrepancy between the two licenses,
8   the BSD license will take precedence.
9   Set tabs to 8.
10
11 */
12
13 class ADODB_pdo_mssql extends ADODB_pdo {
14
15         var $hasTop = 'top';
16         var $sysDate = 'convert(datetime,convert(char,GetDate(),102),102)';
17         var $sysTimeStamp = 'GetDate()';
18
19
20         function _init($parentDriver)
21         {
22
23                 $parentDriver->hasTransactions = false; ## <<< BUG IN PDO mssql driver
24                 $parentDriver->_bindInputArray = false;
25                 $parentDriver->hasInsertID = true;
26         }
27
28         function ServerInfo()
29         {
30                 return ADOConnection::ServerInfo();
31         }
32
33         function SelectLimit($sql,$nrows=-1,$offset=-1,$inputarr=false,$secs2cache=0)
34         {
35                 $ret = ADOConnection::SelectLimit($sql,$nrows,$offset,$inputarr,$secs2cache);
36                 return $ret;
37         }
38
39         function SetTransactionMode( $transaction_mode )
40         {
41                 $this->_transmode  = $transaction_mode;
42                 if (empty($transaction_mode)) {
43                         $this->Execute('SET TRANSACTION ISOLATION LEVEL READ COMMITTED');
44                         return;
45                 }
46                 if (!stristr($transaction_mode,'isolation')) $transaction_mode = 'ISOLATION LEVEL '.$transaction_mode;
47                 $this->Execute("SET TRANSACTION ".$transaction_mode);
48         }
49
50         function MetaTables($ttype=false,$showSchema=false,$mask=false)
51         {
52                 return false;
53         }
54
55         function MetaColumns($table,$normalize=true)
56         {
57                 return false;
58         }
59
60 }