---
title: "wm_concat 使用"
author: "beee"
date: "2013-12-18T19:37:06Z"
tags: []
categories: ["数据库"]
slug: "wm-concat"
draft: false
lastmod: "2013-12-18T19:41:46Z"
id: 1991732
url: "https://beee.iteye.com/blog/1991732"
---

经常用的,自己mark一下,有更好的处理办法希望推荐给我

select tt.c\_fundcode ,  
       wm\_concat (  tt.c\_profitclass||':'||rtrim(to\_char(tt.f\_profit\*100,'fm99999999999990.999999'),'.')||'%') as profit  
from ttrustfundprofit tt where tt.c\_fundcode='005440'  
group by tt.c\_fundcode

  处理前和处理后的对比截图  
![](http://dl2.iteye.com/upload/attachment/0092/2852/1e615932-583e-3a28-b3c7-d98694a2b8ac.png)  
 

![](http://dl2.iteye.com/upload/attachment/0092/2846/03b1c762-191a-3508-9a66-d6058544eab0.png)