位置: 编程技术 - 正文

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

  • 金蝶软件中怎么登记应该税费
  • 财务报表上期金额怎么填写
  • 不单独计价的包装物是什么意思
  • 减税后含税单价计算公式
  • 小规模公司初期注销流程
  • 房产出租增值税税目
  • 坏账准备贷方核算内容
  • 金蝶kis 反结账
  • 审计核减理由
  • 企业合并的会计方法选择
  • 上季度开的发票这季度冲红怎么做会计分录?
  • 营业外支出计入
  • 企业用商业汇票支付购货款
  • 逆流交易固定资产折旧实现,为什么按差额
  • 母子公司有什么关系
  • 纳税人签章填什么
  • 办税人员需要会计证吗
  • 月初开票能抵扣上月的税吗
  • 进项税额转出怎么填申报表
  • 购进电费管理费会计分录
  • 收到财产保险赔款会计分录
  • 资产减值损失是什么类科目
  • 房地产土地增值税加计扣除20%
  • 应收账款贷方余额怎么调平
  • 发票过期未认证怎么办
  • 出纳应做到
  • 劳务费发票证明怎么写
  • 按揭的车可以只买交强险吗
  • 如何使用网络安全
  • 暂估成本比实际高分录
  • 调账的基本原则
  • 收到对方公司开的发票怎么做账
  • 阻止电脑系统更新设置在哪
  • 企业自建廉租房政策
  • ccs ide
  • 继承房产印花税是按交易分额交吗
  • php 函数返回值
  • 企业合并一般债权怎么算
  • 金融工具减值的范围包括哪些?
  • 没进项可以开专票吗
  • frameworks
  • node更新到最新版本
  • html代码form
  • WP Smart Preloader 为你的WordPress添加预加载动画
  • 错误凭证如何修改?所有的错误的凭证都能修改吗?
  • 其他应收款如何计提减值准备
  • 供应商退款需要冲库存商品吗
  • 什么经营范围是营业执照
  • 确定负债排列顺序的依据
  • 关联交易纳税调整期限
  • mongodb修改数据库名称
  • 工程施工人工费,材料费,机械费占多少比例
  • 营业执照备案登记表
  • 企业如何进行促销
  • 中小企业投标费怎么算
  • 银行 收美金
  • 未分配利润太多的危害
  • 在建工程物资属于存货吗
  • 劳务公司机械租赁费列入什么费用
  • 超市发票报销一般写什么明细
  • 固定资产计提折旧的会计科目
  • 购车怎么做会计分录
  • sql语句去除重复值
  • windows的视频
  • xp桌面快捷方式不见了
  • 一键快速关机下载手机版
  • windows阻止
  • 拉伸设置
  • java word操作
  • android开发地图应用
  • div-css
  • firefox margin-top失效的原因与解决办法
  • JavaScript中Number.MAX_VALUE属性的使用方法
  • android开发吧
  • 安卓判断横竖屏
  • 用python编写简单程序
  • jquery中on
  • 企业所得税到底是按间接法计算还是直接法计算
  • 开票系统服务器设置
  • 汽车票用什么查
  • 免责声明:网站部分图片文字素材来源于网络,如有侵权,请及时告知,我们会第一时间删除,谢谢! 邮箱:opceo@qq.com

    鄂ICP备2023003026号

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

    友情链接: 武汉网站建设