当前位置:网站首页>oracle数据库将多个列的查询结果集合并到一行中
oracle数据库将多个列的查询结果集合并到一行中
2022-04-23 06:04:00 【旺财2】
方法一:
select field1,listagg(field3,',') within GROUP (order by field3) from test group by field1;
方法二(在方法一报出所拼接的字符串长度过长时,使用方法二):
select field1,xmlagg(xmlparse(content field3||',' wellformed) order by field3).getclobval() from test1 group by field1
版权声明
本文为[旺财2]所创,转载请带上原文链接,感谢
https://blog.csdn.net/wdyliuxingfeiyang/article/details/122165760
边栏推荐
- 基于ECS搭建云上博客(云小宝码上送祝福,免费抽iphone13任务详解)
- Abnormal record-18
- Abnormal record-19
- Build a cloud blog based on ECS (send blessings on the cloud Xiaobao code and draw iphone13 for free)
- 异常记录-6
- Prometheus Cortex使用Block存储时的相关问题
- Chaos vous emmène au projet chaos.
- Research on alertmanager repeated / missing alarm phenomenon and two key parameters_ Wait and group_ Interpretation of interval
- 基于EMR离线数据分析-反馈有礼
- Practice of openvswitch VLAN network
猜你喜欢
Redis FAQ
专用窗口函数rank, dense_rank, row_number
Construire un blog Cloud basé sur ECS (bénédiction sur le Code Cloud Xiaobao, explication détaillée de la tâche iphone13 gratuite)
搭建基于OSS的图片分享网站-反馈有礼
Dolphinscheduler调度spark任务踩坑记录
Dolphinscheduler集成Flink任务踩坑记录
Information:2021/9/29 10:01 - Build completed with 1 error and 0 warnings in 11s 30ms Error异常处理
Basic concepts of database: OLTP / OLAP / HTAP, RPO / RTO, MPP
volatile 关键字的三大特点【数据可见性、指令禁止重排性、不保证操作原子性】
Static interface method calls are not supported at language level ‘5‘ 异常解决
随机推荐
Basic concepts of database: OLTP / OLAP / HTAP, RPO / RTO, MPP
Dolphinscheduler配置Datax踩坑记录
Exception record-7
Thanos Compactor组件使用
"Write multi tenant" implementation of Prometheus and thanos receiver
pg库对姓名进行校验
BPF program of type XDP
Introduction to DDoS attack / defense
Redis FAQ
[MySQL basics] data export and import permissions and local_ Infile parameter
异常记录-5
Using Prom label proxy to implement label based multi tenant reading of Prometheus thanos
Dolphinscheduler集成Flink任务踩坑记录
异常记录-19
Prometheus Thanos与Cortex组件比较
异常记录-17
JS function package foreach use return can not jump out of the outer function
OSS云存储管理实践(体验有礼)
Prometheus Thanos快速指南
异常记录-8