位置: 编程技术 - 正文

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

  • 公司注销股东收回公司车辆做什么账务处理
  • 邮政电信业务差距大吗
  • 开具增值税发票未报送是什么意思?
  • 车辆购置税如何计算
  • 未投入使用的固体废物
  • 个税手续费返还政策文件
  • 建筑简易征收需要成本发票吗
  • 社保多交退款多久到账
  • 其他综合收益是什么类科目
  • 企业所得税申报表A类
  • 小微企业免税计入什么科目
  • 动漫版权交易
  • 小规模纳税人怎么查询
  • 自建厂房可以不办理房产证吗
  • 报废资产取得的增值税
  • 收到发票怎么记账
  • 福利费要交个人税吗
  • 怎么看公司行不行
  • 一般纳税人开普票多少个点
  • 进项税额转出怎么申报
  • 财务负责人必须是本公司员工吗
  • 应付账款核销法律规定
  • 财报申报逾期可不可以补报
  • 小规模发工资超了怎么办
  • 增值税纳税申报表在哪里打印
  • 建筑设计公司的账务处理
  • 自制原始凭证需要复核
  • 使窗口最小化的快捷键
  • win11电脑下载的软件桌面没有图标怎么办
  • vue项目如何搭建
  • 重装系统j
  • 所得税季度预缴怎么算
  • 买材料没发票怎么办
  • dsregcmd.exe
  • createrectrgn
  • php两个数组相加结果
  • 利尼扬蒂野生动物保护区中的一只雄性豹子,博茨瓦纳 (© Karine Aigner/Tandem Stills + Motion)
  • 销售方收到购买方的红字信息表
  • 原材料明细账有记税吗
  • 企业所得税税前扣除凭证管理办法
  • thinkphp3.0
  • rk3566 rk3288
  • 个税手续费会计分录
  • 专票和普票都有发票吗
  • 消费税为什么要除以1减税率推导公式
  • 发票上的金额是含税还是不含税
  • 部分货物退回怎么开票
  • 企业跨区变更地址需要多久
  • 增值税发票系统客服电话
  • 无形资产是什么?
  • 暂估原材料,材料成本如何冲
  • 工资能否当月计提当月发放
  • 三方协议代付的钱在哪里
  • 会计中预付账款
  • 固定资产折旧递延收益
  • 会计处理的步骤
  • 置换房产怎么交税
  • 固定资产的改良支出有哪些
  • 人力资源外包服务费计入什么科目
  • 相关损坏维修成本是什么
  • 出口退税转为免税处理有损失吗
  • 行政事业单位计提工资怎么做账
  • 政府奖励企业如何领取
  • 开餐饮店需要什么条件才能开
  • 企业股东的出资方式
  • mysql替换命令
  • sql server存储过程教程
  • iis6配置网站
  • 详述社会体育学科的研究对象
  • 怎么删除swapfile
  • win8共享文件
  • win10修复dllregisterserver
  • linux sort命令参数及用法详解
  • 服务器防arp欺骗怎么解决
  • 解决的英文
  • 装饰装修公司需要什么
  • 甘肃税务局电子税务局app
  • 依法纳税的看法
  • 财税公众号名称大全
  • 北京朝阳国家税务总局
  • 免责声明:网站部分图片文字素材来源于网络,如有侵权,请及时告知,我们会第一时间删除,谢谢! 邮箱:opceo@qq.com

    鄂ICP备2023003026号

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

    友情链接: 武汉网站建设