位置: 编程技术 - 正文

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

  • 房地产预缴增值税计算方式
  • 外贸企业税务处理方式
  • 天猫提现一直没到账
  • 加班费计入个税吗
  • 收到劳务发票还未付款
  • 合伙企业交企业所得税还是个人所得税
  • 冲红的发票税款计提分录要冲红吗
  • 行政单位会议纪要范文3篇
  • 小企业会计准则以前年度损益调整
  • 分步法和分批法思维导图
  • 股票盈亏怎么计算app
  • 股东实物分红账务怎么做
  • 短期筹资方式有没有股票
  • 报表中应交税金和应交税费区别
  • 招标代理公司转让
  • 算材料成本的时候要算增值税吗?
  • 跨年收入没有进项发票怎么做帐?
  • 进项税申报但未抵扣
  • 公司发实物要交税吗
  • 变更公司名称注册时间会变吗
  • 会计人必读的20本书
  • 收汇结汇的账务处理
  • 票开了但是没有发票
  • 托收承付是什么意思?
  • 损益类账户包括成本类吗
  • 社保申报怎么查询
  • 审计调账后企业怎么处理
  • 机械租赁有什么机械
  • 空白发票怎么用
  • 企业销售食品过期处罚
  • 增值税系统技术维护费需要勾选吗
  • 企业计提的坏帐会计分录
  • 预付维修费计入入账价值吗
  • win10锁屏壁纸自动更新
  • 雨林木风win10安装失败
  • 集团公司交税怎么交?
  • 网速第一的国家
  • zendframework3中文手册
  • npm无法将npm项识别为
  • 非成品柴油用途
  • 图片格式转换pdf
  • 高通芯片开发
  • 汽车折旧年限是几年内的
  • 原材料盘盈会计处理
  • 钢材贸易公司如何经营
  • 保险公司作为奖金怎么算
  • 资产负债表一般由什么组成
  • 收到分红的会计科目
  • 交易性金融资产包括哪些项目
  • 坏账损失的定义
  • 银行承兑到期后未兑付
  • 预缴所得税科目
  • 新会计准则印花税规定
  • 收了对方预付款怎么打条
  • 进口消费品增值税计税依据
  • 发票怎么跨月作废申请
  • 红字发票是怎么开的
  • 保险公司理赔款如何入账
  • 跨月发票作废怎么做会计分录
  • sqlserver比较日期时间
  • Win8系统Smartscreen筛选器界面变灰无法设置的解决方法
  • win8最新版本
  • 系统设置技巧有哪些
  • 升级windows8
  • windows10mobile官网
  • win10 提示你的设备遇到问题 需要重新启动
  • 怎么调用windows api
  • win8创建我的电脑
  • unity加密解决方案
  • opengl 旋转矩阵
  • opengl怎么学
  • react either
  • java入门怎么学
  • gridview用法
  • 猫的游戏视频
  • js table
  • 酒类包装物押金的消费税处理规定
  • 消费税要把增值税算进去吗
  • 济南高新区地税局地址
  • 免责声明:网站部分图片文字素材来源于网络,如有侵权,请及时告知,我们会第一时间删除,谢谢! 邮箱:opceo@qq.com

    鄂ICP备2023003026号

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

    友情链接: 武汉网站建设