mirror of
https://github.com/dg/dibi.git
synced 2025-01-17 14:18:25 +01:00
updated examples
This commit is contained in:
parent
322a110f75
commit
10fdecfc13
@ -9,8 +9,8 @@ require_once '../dibi/dibi.php';
|
||||
|
||||
|
||||
dibi::connect(array(
|
||||
'driver' => 'sqlite',
|
||||
'database' => 'data/sample.sdb',
|
||||
'driver' => 'sqlite3',
|
||||
'database' => 'data/sample.s3db',
|
||||
));
|
||||
|
||||
|
||||
@ -56,3 +56,11 @@ dibi::test('
|
||||
%else 1 LIMIT 10 %end'
|
||||
);
|
||||
// -> SELECT * FROM customers WHERE LIMIT 10
|
||||
|
||||
|
||||
|
||||
// IF()
|
||||
dibi::test('UPDATE products SET', array(
|
||||
'price' => array('IF(price_fixed, price, ?)', 123),
|
||||
));
|
||||
// -> SELECT * FROM customers WHERE LIMIT 10
|
||||
|
@ -11,8 +11,8 @@ date_default_timezone_set('Europe/Prague');
|
||||
|
||||
|
||||
dibi::connect(array(
|
||||
'driver' => 'sqlite',
|
||||
'database' => 'data/sample.sdb',
|
||||
'driver' => 'sqlite3',
|
||||
'database' => 'data/sample.s3db',
|
||||
));
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user