如何将两列合并为一列 [英] How to merge two columns into one column

查看:145
本文介绍了如何将两列合并为一列的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们有Visual Studio 2015.我们有一个平面文件源(CSV),它有两列我们要合并到SQL Server表中的一列。两个输入列是"Fans(LIfetime)"。和"LinkedInFollowers"。 SQL中的列是"Fans
(Lifetime)"。基本上我们想将LinkedFollowers数据合并到Fans(Lifetime)数据中。这是我们正在使用的数据源。日期字段转换的数据转换步骤。看看Merge和Union All可能的方法,但
没有运气。

We have Visual Studio 2015. We have a flat file source (CSV) with two columns that we want to merger into one column in the SQL Server table. The two input columns are "Fans (LIfetime)" and "LinkedInFollowers". The column in SQL is "Fans (Lifetime)". Basically we want to Merge the LinkedFollowers data into the Fans (Lifetime) data. This is the data source we are using. The data conversion step of for a date field conversion. Looked at Merge and Union All as possible ways to do this but no luck.

推荐答案

嗨  TWIKLE,

目前还不清楚你要做什么,即" ... 我们要合并到一列中的两列...... "

It is not so clear what you are trying to do, i.e. "...two columns that we want to merger into one column..."

我假设您需要连接 2列,类似于FirstName + LastName = FullName。

I am assuming that you need to concatenate 2 columns, similar to FirstName + LastName = FullName.

为此,您可以使用SSIS 派生列转换。在其表达式构建器中,您将连接任何表达式。

For that, you can use SSIS Derived Column Transformation. In its expression builder you would concatenate any expression.


这篇关于如何将两列合并为一列的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆