Asf_Db_AbstractQueryBuilder::orWhere


Description

public object orwhere(string $columns, mixed $value [, string $operator = '='])

Parameters

columns

数据库字段名称

value

字段的值

operator

操作符 =, !=, <, >

Return Values

操作成功返回 Object, 失败返回 false

Examples

Example #1

<?php
use Asf\Db\QueryBuilder\Select;

$select = new Select();
$select->cols()
    ->from('test')
    ->OrWhere(0, 1)
    ->OrWhere('user', 1);

// string(73) "[SQL] SELECT * FROM `test` WHERE `0` = ? OR `user` = ? [BVALUES] 1 , 1"
var_dump($select->show());