导入到SQL Server时忽略Excel文件中的列 [英] Ignoring column from Excel file while importing to SQL Server

查看:112
本文介绍了导入到SQL Server时忽略Excel文件中的列的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有多个具有相同格式的Excel文件。我需要将它们导入SQL Server。

I have multiple Excel files that have the same format. I need to import them into SQL Server.

我目前遇到的问题是,我需要完全忽略两个文本列,因为它们是自由文本,并且某些行的字符长度超出了服务器允许的范围我要导入,这会导致截断错误。

The issue I currently have is that there are two text columns that I need to ignore completely as they are free text and the character length for some rows exceeds what the server allows me to import which results in a truncation error.

由于我不需要这些列来进行分析,因此我要导入的表中不包含这些列,但由于某些原因,SSIS包仍然可以使用

Because I don't need these columns for my analysis, the table I'm importing to doesn't include these columns but for some reason the SSIS packages still picks up those columns and cuts the import job halfway through.

我尝试为这些列使用最大字符长度,但这仍然会导致截断错误。

I tried using max character length for those columns which still results in the truncation error.

我需要创建一个SSIS程序包,该程序包将完全忽略两列而无需从Excel中删除这些列。

I need to create an SSIS package that ignores the two columns completely without deleting the columns from Excel.

推荐答案

您可以从编辑映射对话框中指定需要忽略的列。

You can specify which columns you need to ignore from the Edit Mappings dialog.

我已添加图像供您参考:

I have added the image for your reference:

这篇关于导入到SQL Server时忽略Excel文件中的列的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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