位置: 编程技术 - 正文

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函数

  • 收到退个税手续费要交增值税吗?
  • 税务定税按什么标准
  • 运输企业内账
  • 向职工支付困难证明材料
  • 更正以前年度费用账务处理
  • 差旅费津贴需要缴纳个人所得税吗?
  • 租车开发票属于什么类
  • 购进的库存商品转自用需要开发票吗
  • 商业企业的商品销售额、职工人数是( )
  • 个人住房契税2021年收费标准
  • 监督审核费用会计入账
  • 捐款怎样抵扣个税
  • 企业购买房屋的行为涉及哪些税种
  • 旧设备进口关税
  • 非本单位费用列支 违反
  • 退货或者销毁处理
  • 采购工程物资会议纪要
  • 增值税专用发票使用规定 最新
  • 账本印花税每年交吗,要交几本
  • 企业购进货物若发生下列事项,其增值税进项税额
  • 企业支付在哪里
  • 外包人员培训费入什么科目
  • 车辆完税证明怎么弄
  • 季度报税过了怎么办
  • 电子商务出来干嘛
  • 增值税的征收范围包括在中华人民共和国境内
  • 默认网关不可用修复后过一会又不好使了
  • 治理层和管理层包括哪些
  • 一般纳税人增值税申报表怎么填写
  • win10电脑文件夹打不开
  • 企业购地流程
  • 批量删除 超链接
  • php怎么实现代码运行功能
  • 商业承兑汇票提示承兑期限
  • 保证金结息的会计分录
  • ati2plab.exe是什么进程 ati2plab进程安全吗
  • php基础入门教程
  • php如何实现登录和注册
  • php curl代理
  • 工业会计和商业会计有什么区别
  • gpt3 transformer
  • php 缓存
  • 开负数发票的规定是有?
  • 改签机票要收费
  • 税金及附加怎么做分录
  • 安装sql server 2005,安装不成功怎么设置
  • 员工工资应要计入什么
  • 代理费属于
  • 固定资产一次性扣除账务处理
  • 支付税务罚款计入什么科目
  • 发票与销售小票有什么区别?
  • 年金现值的含义
  • 计提销售费用什么意思
  • 发放工资社保的账务处理
  • 代理进口产品
  • 销售费用包括什么?
  • 期末存货采用成本与什么孰低法计价
  • 银行存款日记账对方科目两个怎么办
  • 成品油 规定
  • centos5.5网络配置
  • centos6.8修改主机名
  • 系统播放音乐
  • linux 管道实现
  • [置顶] 此外,车牌号:458143(懂得都懂[吃瓜])
  • cocos2dx4.0入门
  • easyui点击弹出窗口
  • perl中qw
  • awk命令使用什么变量存储行号
  • shell获取字符串中的数字
  • js测试工具
  • 在谈到民族这个概念是我们一再指出
  • js设置页面大小
  • unity怎么录屏
  • android 字体设置
  • android java编程
  • 江苏税务新办企业套餐
  • 安阳文峰区小学招生
  • 重庆电子税务局怎么绑定办税人员
  • 货车附加费多少钱
  • 出口退税函调管理办法
  • 免责声明:网站部分图片文字素材来源于网络,如有侵权,请及时告知,我们会第一时间删除,谢谢! 邮箱:opceo@qq.com

    鄂ICP备2023003026号

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

    友情链接: 武汉网站建设