当前位置:网站首页>If there is out in PG function, returns setof record as is ignored$$
If there is out in PG function, returns setof record as is ignored$$
2022-07-22 05:02:00 【howard_ shooter】
If you create PG function , Returned values , In the parameter list OUT Statement in , You can also not declare , And specify the column definition of the return record when calling .
for example :
CREATE OR REPLACE FUNCTION BrokerVolumeFrame1 (
IN in_broker_list VARCHAR[],
IN in_sector_name VARCHAR,
OUT broker_name VARCHAR(100)[],
OUT list_len INTEGER,
OUT volume NUMERIC(14, 2)[])
RETURNS SETOF record AS $$
DECLARE
...
It is equivalent to returning a column defined as :
(broker_name VARCHAR(100)[],list_len INTEGER,volume NUMERIC(14, 2)[])
The record of .
If not used OUT The parameter defines the column of the return record , When calling, you need to specify :
SELECT * FROM BrokerVolumeFrame1('{Ronald Y. Thatch, Windy J. Handrick}','Consumer Non-Cyclical') as bvf1 (broker_name VARCHAR(100)[], list_len INTEGER, volume NUMERIC(14, 2)[]);
Use OUT Back to the record , Only one line of records can be returned , meanwhile “RETURNS SETOF record AS $$” Be ignored .
边栏推荐
- Niuke.com released a new digital logic question bank! Will it lead to more volume in fpga/ic industry this year?!!
- HCIP笔记整理 2022/7/15
- eslint的命令行使用
- 【板栗糖GIS】wps——如何将空格填充上一行的内容
- Yunzhou intelligent IPO was terminated: the annual revenue was 250million, the loss was 130million, and it was planned to raise 1.55 billion
- 岛屿数量vs最大正方形
- 让Matplotlib、Seaborn数据图动起来~
- scratch成绩查询 电子学会图形化编程scratch等级考试四级真题和答案解析2022年6月
- 软考 系统架构设计师 简明教程 | 软件开发模型
- Qt之Model/View架构
猜你喜欢
岛屿数量vs最大正方形
DRF -- cross domain problem solving
柠萌影视通过聆讯:年营收12亿 腾讯与芒果文创是股东
SDL2 简明教程(二):创建一个空的窗口
Here comes the multilingual model that everyone can use! Support 59 languages, parameters 176billion, 1000 scientists jointly launched
专访SPORTFIVE李莹:如何用Web3的方式推动体育IP拓展“新商业版图”
从0写bootloader — Bootloader重定位APP
【苏州大学】考研初试复试资料分享
联影医疗通过注册:拟募资125亿 薛敏控制32%股权
【模糊神经网络】基于simulink的模糊神经网络控制器设计
随机推荐
The latest Hubei construction safety officer simulation question bank and answers in 2022
jvm初识
Mapstruct code generator realizes object transformation
图像文本跨模态细粒度语义对齐-置信度校正机制 AAAI2022
SDL2 简明教程(一):使用 Cmake 和 Conan 构建 SDL2 编程环境
Understand the volatile implementation of JVM from the bottom, CPU cache, cache consistency MESI, store bufferi, nvalidate queue and other knowledge
leetcode:814. 二叉树剪枝【dfs】
DRF -- users user module
【板栗糖GIS】bat—怎么删除子文件夹下的同后缀名的数据
【板栗糖GIS】如何批量删除多个文件夹里的同名空文件
Some problems in the idea have been solved (the package problem handling method cannot be found, and the download has been completed, but the idea cannot detect the package)
《安富莱嵌入式周报》第274期:2022.07.11--2022.07.17
Yunzhou intelligent IPO was terminated: the annual revenue was 250million, the loss was 130million, and it was planned to raise 1.55 billion
Introduction to excellent verilog/fpga open source project (XXIX) - open source website
05mysql的锁分析
A little cool, use Net Maui exploring space
振华风光半导体通过注册:年营收5亿 中国电子是实控人
Research on decompilation of wechat applet
有点酷,使用 .NET MAUI 探索太空
【板栗糖GIS】腾讯会议的个人用户如何改名