成人精品一区二区三区中文字幕-成人精品一区二区三区-成人精品一级毛片-成人精品亚洲-日本在线视频一区二区-日本在线视频免费

導航首頁 ? 技術教程 ? PHP:pg_fetch_all_columns()的用法_PostgreSQL函數
全站頭部文字 我要出現在這里
PHP:pg_fetch_all_columns()的用法_PostgreSQL函數 820 2023-12-12   

pg_fetch_all_columns

(PHP 5 >= 5.1.0)

pg_fetch_all_columns — Fetches all rows in a particular result column as an array

說明

array pg_fetch_all_columns ( resource $result [, int $column = 0 ] )

pg_fetch_all_columns() returns an array that contains all rows (records) in a particular column of the result resource.

Note: 此函數將 NULL 字段設置為 PHP NULL 值。

參數

result

PostgreSQL query result resource, returned by pg_query(), pg_query_params() or pg_execute() (among others).

column

Column number, zero-based, to be retrieved from the result resource. Defaults to the first column if not specified.

返回值

An array with all values in the result column.

FALSE is returned if column is larger than the number of columns in the result, or on any other error.

范例

Example #1 pg_fetch_all_columns() example

<?php 
$conn = pg_pconnect("dbname=publisher");
if (!$conn) {
  echo "An error occurred.n";
  exit;
}

$result = pg_query($conn, "SELECT title, name, address FROM authors");
if (!$result) {
  echo "An error occurred.n";
  exit;
}

// Get an array of all author names
$arr = pg_fetch_all_columns($result, 1);

var_dump($arr);

?>

參見

pg_fetch_all() - 從結果中提取所有行作為一個數組


主站蜘蛛池模板: 同悲万古尘| 魏子翔| junk boy| 无耻之徒英文| 李洋个人资料照片| la ciociara| 刘浩存个人简历图片| 包青天开封奇案| 蛇谷奇兵 电影| 风流一代电影| 就义诗诗配画| 情事:秘密情事| 打美女光屁股视频网站 | 杨子姗演过的电影电视剧| 搜狐视频官网| 男保姆| 对你的爱歌词| 杨采钰电影| 最新欧美电影| 电子元器件基础知识| xxxxxxxxxxxx| 老公看你的| 囚徒 电影| 浪荡子的旅程电影| 国考岗位| 火烈女囚| 何时何地因何种原因受过何种奖励或处分 | 侦探们的镇魂歌国语版在线观看| 萱草花合唱谱二声部| 影片 - theav| free hd xxxx moms movie777| 接吻教学视频| 密桃成孰时| 即日启程 电影| 斯维特拜克之歌| 美女上厕所| 国产精品欧美大片| 美女上厕所| 林栋浦| 漂亮小蜜桃| 韩国一对一电影|

?。?!站長長期在線接!??!

網站、小程序:定制開發/二次開發/仿制開發等

各種疑難雜癥解決/定制接口/定制采集等

站長微信:lxwl520520

站長QQ:1737366103