1--TEST-- 2SQLite3::changes() tests 3--SKIPIF-- 4<?php require_once(__DIR__ . '/skipif.inc'); ?> 5--FILE-- 6<?php 7 8require_once(__DIR__ . '/new_db.inc'); 9define('TIMENOW', time()); 10 11echo "Creating Table\n"; 12var_dump($db->exec('CREATE TABLE test (time INTEGER, id STRING)')); 13 14echo "INSERT into table\n"; 15var_dump($db->exec("INSERT INTO test (time, id) VALUES (" . TIMENOW . ", 'a')")); 16var_dump($db->exec("INSERT INTO test (time, id) VALUES (" . TIMENOW . ", 'b')")); 17 18echo "UPDATE query\n"; 19var_dump($db->exec("UPDATE test SET id = 'c'")); 20 21echo "Rows Updated\n"; 22var_dump($db->changes()); 23 24echo "Closing database\n"; 25var_dump($db->close()); 26echo "Done\n"; 27?> 28--EXPECT-- 29Creating Table 30bool(true) 31INSERT into table 32bool(true) 33bool(true) 34UPDATE query 35bool(true) 36Rows Updated 37int(2) 38Closing database 39bool(true) 40Done 41