PHP 클래스 SelectQuery, fluentpdo

상속: extends QuerySkeleton, implements Named, implements JoinCapableQuery, implements Aliased
파일 보기 프로젝트 열기: fpdo/fluentpdo 1 사용 예제들

공개 메소드들

메소드 설명
__construct ( FluentPDO $fpdo, $from ) SelectQuery constructor.
count ( ) : integer Countable interface doesn't break current \FluentPDO select query
fetch ( string $column = '' ) : mixed Fetch first row or column
fetchAll ( string $index = '', string $selectOnly = '' ) : array Fetch all row
fetchColumn ( integer $columnNumber ) : string Returns a single column
fetchPairs ( $key, $value, $object = false ) : array Fetch pairs
getFromAlias ( ) Return table alias from FROM clause
getFromTable ( ) Return table name from FROM clause
getIterator ( )

메소드 상세

__construct() 공개 메소드

SelectQuery constructor.
public __construct ( FluentPDO $fpdo, $from )
$fpdo FluentPDO
$from

count() 공개 메소드

Countable interface doesn't break current \FluentPDO select query
public count ( ) : integer
리턴 integer

fetch() 공개 메소드

Fetch first row or column
public fetch ( string $column = '' ) : mixed
$column string column name or empty string for the whole row
리턴 mixed string, array or false if there is no row

fetchAll() 공개 메소드

Fetch all row
public fetchAll ( string $index = '', string $selectOnly = '' ) : array
$index string specify index column
$selectOnly string select columns which could be fetched
리턴 array of fetched rows

fetchColumn() 공개 메소드

Returns a single column
public fetchColumn ( integer $columnNumber ) : string
$columnNumber integer
리턴 string

fetchPairs() 공개 메소드

Fetch pairs
public fetchPairs ( $key, $value, $object = false ) : array
$key
$value
$object
리턴 array of fetched rows as pairs

getFromAlias() 공개 메소드

Return table alias from FROM clause
public getFromAlias ( )

getFromTable() 공개 메소드

Return table name from FROM clause
public getFromTable ( )

getIterator() 공개 메소드

public getIterator ( )