位置: 编程技术 - 正文

PHP:pg_send_execute()的用法_PostgreSQL函数

编辑:rootadmin
pg_send_execute

推荐整理分享PHP:pg_send_execute()的用法_PostgreSQL函数,希望有所帮助,仅作参考,欢迎阅读内容。

文章相关热门搜索词:,内容如对您有帮助,希望把文章链接给更多的朋友!

(PHP 5 >= 5.1.0)

pg_send_execute — Sends a request to execute a prepared statement with given parameters, without waiting for the result(s).

说明 bool pg_send_execute ( resource $connection , string $stmtname , array $params )

Sends a request to execute a prepared statement with given parameters, without waiting for the result(s).

This is similar to pg_send_query_params(), but the command to be executed is specified by naming a previously-prepared statement, instead of giving a query string. The function&#;s parameters are handled identically to pg_execute(). Like pg_execute(), it will not work on pre-7.4 versions of PostgreSQL.

参数

connection PHP:pg_send_execute()的用法_PostgreSQL函数

PostgreSQL database connection resource. When connection is not present, the default connection is used. The default connection is the last connection made by pg_connect() or pg_pconnect().

stmtname

The name of the prepared statement to execute. if "" is specified, then the unnamed statement is executed. The name must have been previously prepared using pg_prepare(), pg_send_prepare() or a PREPARE SQL command.

params

An array of parameter values to substitute for the $1, $2, etc. placeholders in the original prepared query string. The number of elements in the array must match the number of placeholders.

返回值

Returns TRUE on success, FALSE on failure. Use pg_get_result() to determine the query result.

范例

Example #1 Using pg_send_execute()

<?php$dbconn=pg_connect("dbname=publisher")ordie("Couldnotconnect");//Prepareaqueryforexecutionif(!pg_connection_busy($dbconn)){pg_send_prepare($dbconn,"my_query",'SELECT*FROMshopsWHEREname=$1');$res1=pg_get_result($dbconn);}//Executethepreparedquery.Notethatitisnotnecessarytoescape//thestring"Joe'sWidgets"inanywayif(!pg_connection_busy($dbconn)){pg_send_execute($dbconn,"my_query",array("Joe'sWidgets"));$res2=pg_get_result($dbconn);}//Executethesamepreparedquery,thistimewithadifferentparameterif(!pg_connection_busy($dbconn)){pg_send_execute($dbconn,"my_query",array("ClothesClothesClothes"));$res3=pg_get_result($dbconn);}?>

参见

pg_prepare() - Submits a request to create a prepared statement with the given parameters, and waits for completion. pg_send_prepare() - Sends a request to create a prepared statement with the given parameters, without waiting for completion. pg_execute() - Sends a request to execute a prepared statement with given parameters, and waits for the result.

PHP:pg_select()的用法_PostgreSQL函数 pg_select(PHP4=4.3.0,PHP5)pg_select选择记录说明mixedpg_select(resource$connection,string$table_name,array$assoc_array[,int$options=PGSQL_DML_EXEC])pg_select()根据assoc_array数组中的field=v

PHP:pg_result_status()的用法_PostgreSQL函数 pg_result_status(PHP4=4.2.0,PHP5)pg_result_status获得查询结果的状态说明intpg_result_status(resource$result)pg_result_status()返回该查询结果资源的状态。可能的返回值有PGSQ

PHP:pg_result_seek()的用法_PostgreSQL函数 pg_result_seek(PHP4=4.3.0,PHP5)pg_result_seek在结果资源中设定内部行偏移量说明arraypg_result_seek(resource$result,int$offset)pg_result_seek()在结果资源中设定内部行偏移量

标签: PHP:pg_send_execute()的用法_PostgreSQL函数

本文链接地址:https://www.jiuchutong.com/biancheng/281448.html 转载请保留说明!

上一篇:PHP:pg_send_prepare()的用法_PostgreSQL函数

下一篇:PHP:pg_select()的用法_PostgreSQL函数

  • 预收账款的税费怎么处理
  • 企业当期的所得税费用
  • 城建税计税依据扣除增值税期末留抵
  • 纳税申报财务报表上期数
  • 企业购进软件系统后如何做账
  • 灭火器属于什么经营范围
  • 劳务公司劳务工资做什么科目
  • 慰问金计入什么明细科目
  • 维修企业主营项目有哪些
  • 企业处置固定资产
  • 投资性房地产转固定资产账务处理
  • 以前年度的收入怎么调整
  • 境内企业转让境外股权税收
  • 增值税的附加
  • 贷款利息增值税发票
  • 建筑业简易征收的适用范围
  • 分公司如何缴纳公积金
  • 一般纳税人外经证预缴怎样缴费
  • 建筑业预缴增值税税率
  • 增值税普通发票怎么开
  • 什么样的凭证是原始凭证
  • 调整薪酬结构
  • 交易性金融资产的账务处理
  • 因为质量问题
  • 网上代开专票 附加税在哪看
  • 买车的发票可以抵扣吗?
  • 苹果mac os x 怎样打开DVD播放程序
  • 怎么操作win10系统
  • 专有技术应当得到
  • 图像类别
  • 苹果语音备忘录怎么导出
  • 企业所得税涉税风险通知书
  • 什么时候使用多进程
  • 系统win7旗舰版
  • 福利企业的税收怎么算
  • 加工制造业包括
  • 劳务报酬所得包括哪些
  • wordpress调用指定文章
  • 存货非正常损失进项税额转出
  • h5页面跳转小程序不显示按钮
  • php中的pdo
  • 资本化的研发费用计入什么科目
  • chrome安装教程
  • 交易性金融资产的入账价值
  • python3矩阵求逆
  • 深入解读何暮楚
  • 认缴制注册资金不交可以吗
  • 印花税怎么申报2023
  • 员工餐费补助交个人所得税吗
  • 房地产企业开发成本科目明细
  • 低值易耗品的
  • sqlserver导入导出数据库
  • 增值税是指怎样计算的
  • 残保金季报还是月报
  • 融资租赁与按揭的区别
  • 免抵税额分录
  • 存货的进口关税计入成本吗
  • 应收票据和应收账款减少说明什么
  • 什么是权责发生会计处理基础
  • 公司的私账
  • 凭证上的数字金额怎么填
  • sqlserver批处理
  • centos7.6 yum源
  • wpr是什么软件
  • linux输出结果
  • mac os固件下载
  • centos安装详细
  • win7系统无法进入登录界面
  • js匿名函数作用域
  • 如何正确使用零钱
  • node+express+ejs制作简单页面上手指南
  • 安卓返回按钮图标
  • unity开发游戏教程
  • android隐藏图片
  • python 入门
  • 可以跨区办理税务ukey更换吗
  • 个体户注销税盘需要公章吗
  • 周报要素
  • 银行缴纳印花税存在问题和建议
  • 代理记账代理记账价格
  • 免责声明:网站部分图片文字素材来源于网络,如有侵权,请及时告知,我们会第一时间删除,谢谢! 邮箱:opceo@qq.com

    鄂ICP备2023003026号

    网站地图: 企业信息 工商信息 财税知识 网络常识 编程技术

    友情链接: 武汉网站建设