当前位置:网站首页>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
边栏推荐
- Abnormal record-10
- pycharm Install packages failed
- Prometheus Cortex架构概述(水平可扩展、高可用、多租户、长期存储)
- Oracle RAC数据库实例启动异常问题分析IPC Send timeout
- 异常记录-16
- [MySQL basics] startup options and configuration files
- Ali vector library Icon tutorial (online, download)
- Exception record-8
- Introduction to DDoS attack / defense
- 10g数据库使用大内存主机时不能启动的问题
猜你喜欢
Dolphinscheduler源码包src.tar.gz解压问题
Prometheus Cortex架构概述(水平可扩展、高可用、多租户、长期存储)
MySQL索引【数据结构+索引创建原则】
基于ECS搭建云上博客(云小宝码上送祝福,免费抽iphone13任务详解)
Relabel of Prometheus_ Configs and metric_ relabel_ Configs explanation and usage examples
Redis 详解(基础+数据类型+事务+持久化+发布订阅+主从复制+哨兵+缓存穿透、击穿、雪崩)
Static interface method calls are not supported at language level ‘5‘ 异常解决
Winter combat camp hands-on combat - MySQL database rapid deployment practice lead mouse cloud Xiaobao
通过源码探究@ModelAndView如何实现数据与页面的转发
Typical application scenarios of alicloud log service SLS
随机推荐
微服务架构核心概念
异常记录-5
异常记录-14
pg库对姓名进行校验
Introduction to RDMA
select命令产生redo日志问题的分析
Typical application scenarios of alicloud log service SLS
Error alarm of Postgres master-slave replication delay monitoring
Kubernetes coredns FAQ reference
异常记录-17
[MySQL basics] startup options and configuration files
Analysis of Rdam principle
RAC环境集群组件gipc无法正确识别心跳网络状态问题分析
关于Postgres主从复制延迟监控的错误告警问题
Introduction to DDoS attack / defense
Dolphinscheduler配置Datax踩坑记录
Dolphinscheduler调度sql任务建表时The query did not generate a result set异常解决
Chaos takes you to the chaos project quickly
timestamp隐式转换问题导致索引列未使用问题分析
Thanos compact component test summary (processing historical data)