summaryrefslogtreecommitdiff
path: root/ext/interbase/tests/ibase_trans_002.phpt
blob: be7c073ca390dc62b39d30465c7aee74cbb59f4f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
--TEST--
ibase_trans(): Basic operations
--SKIPIF--
<?php include("skipif.inc"); ?>
--FILE--
<?php

require("interbase.inc");

$x = ibase_connect($test_base);

$trans = ibase_trans(IBASE_DEFAULT, $x);
$sth = ibase_prepare($trans, 'INSERT INTO test1 VALUES (?, ?)');

$res = ibase_execute($sth, 100, 100);
var_dump($res);

ibase_commit($trans);

$rs = ibase_query($x, 'SELECT * FROM test1 WHERE i = 100');
var_dump(ibase_fetch_assoc($rs));

ibase_free_query($sth);
unset($res);

?>
--EXPECT--
int(1)
array(2) {
  ["I"]=>
  int(100)
  ["C"]=>
  string(3) "100"
}