protected function OAuthStorePDO::query_row in Lingotek Translation 7.7
Same name and namespace in other branches
- 7.2 lib/oauth-php/library/store/OAuthStorePDO.php \OAuthStorePDO::query_row()
- 7.3 lib/oauth-php/library/store/OAuthStorePDO.php \OAuthStorePDO::query_row()
- 7.4 lib/oauth-php/library/store/OAuthStorePDO.php \OAuthStorePDO::query_row()
- 7.5 lib/oauth-php/library/store/OAuthStorePDO.php \OAuthStorePDO::query_row()
- 7.6 lib/oauth-php/library/store/OAuthStorePDO.php \OAuthStorePDO::query_row()
* Perform a query, return the first row * *
Parameters
string sql: * @param vararg arguments (for sprintf) * @return array
Overrides OAuthStoreSQL::query_row
1 call to OAuthStorePDO::query_row()
- OAuthStorePDO::query_one in lib/
oauth-php/ library/ store/ OAuthStorePDO.php - * Perform a query, return the first column of the first row * *
File
- lib/
oauth-php/ library/ store/ OAuthStorePDO.php, line 143
Class
Code
protected function query_row($sql) {
$sql = $this
->sql_printf(func_get_args());
try {
$all = $this->conn
->query($sql, PDO::FETCH_NUM);
$row = array();
foreach ($all as $r) {
$row = $r;
break;
}
} catch (PDOException $e) {
$this
->sql_errcheck($sql);
}
return $row;
}