3 V4.22 15 Apr 2004 (c) 2000-2004 John Lim (jlim@natsoft.com.my). 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.
7 Set tabs to 4 for best viewing.
9 Latest version is available at http://php.weblogs.com/
11 Support Borland Interbase 6.5 and later
15 include_once(ADODB_DIR . "/drivers/adodb-ibase.inc.php");
17 class ADODB_borland_ibase extends ADODB_ibase
19 var $databaseType = "borland_ibase";
21 function ADODB_borland_ibase()
28 $arr['dialect'] = $this->dialect;
29 switch ($arr['dialect']) {
32 $s = 'Interbase 6.5, Dialect 1';
35 $s = 'Interbase 6.5, Dialect 2';
39 $s = 'Interbase 6.5, Dialect 3';
42 $arr['version'] = '6.5';
43 $arr['description'] = $s;
47 // Note that Interbase 6.5 uses ROWS instead - don't you love forking wars!
48 // SELECT col1, col2 FROM table ROWS 5 -- get 5 rows
49 // SELECT col1, col2 FROM TABLE ORDER BY col1 ROWS 3 TO 7 -- first 5 skip 2
51 // SELECT FIRST 5 SKIP 2 col1, col2 FROM TABLE
52 function &SelectLimit($sql, $nrows = -1, $offset = -1, $inputarr = false, $secs2cache = 0)
55 if ($offset <= 0) $str = " ROWS $nrows ";
58 $b = $offset + $nrows;
59 $str = " ROWS $a TO $b";
64 $str = " ROWS $a TO 999999999"; // 999 million
68 return ($secs2cache) ?
69 $this->CacheExecute($secs2cache, $sql, $inputarr)
71 $this->Execute($sql, $inputarr);
78 class ADORecordSet_borland_ibase extends ADORecordSet_ibase
81 var $databaseType = "borland_ibase";
83 function ADORecordSet_borland_ibase($id, $mode = false)
85 $this->ADORecordSet_ibase($id, $mode);