Solved

How to check if a particular column exists in flat file source in SSIS

Posted on 2013-05-29
4
1,506 Views
Last Modified: 2016-02-10
I have to process few flat files to insert their data in one table in one database. But there is one particular column (LastPromotionDate) that may exist in few of the files but not in all. Now for files where it is existing, its value is to be inserted in corresponding column LastPromotionDate in the destination table. But for files where it is not existing, I have to use some variable value as input to the corresponding column LastPromotionDate in the destination table. Is it possible? If YES then how, which type of transformation to be used and how?
0
Comment
Question by:sachitjain
  • 2
4 Comments
 
LVL 19

Accepted Solution

by:
Bhavesh Shah earned 300 total points
ID: 39206862
0
 
LVL 12

Author Comment

by:sachitjain
ID: 39206976
Hi Brichsoft,

The link provided by you talks about existence of file at a particular path but not existence of particular column in the file.
0
 
LVL 21

Assisted Solution

by:Alpesh Patel
Alpesh Patel earned 200 total points
ID: 39228060
Hi

Fist check the source using normal file read of headers
or
DAta profiling task you just check.


If column not exists then do with one data flow and file source where column is not exist.
else other dataflow in that file source has column.

http://www.experts-exchange.com/Microsoft/Development/MS-SQL-Server/SSIS/A_9495-Data-Profiling-Task-to-Validate-data-before-load-to-EDW.html
0
 
LVL 12

Author Closing Comment

by:sachitjain
ID: 39228234
Thanks
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

If you have heard of RFC822 date formats, they can be quite a challenge in SQL Server. RFC822 is an Internet standard format for email message headers, including all dates within those headers. The RFC822 protocols are available in detail at:   ht…
My client sends data in an Excel file to me to load them into Staging database. The file contains many sheets that they have same structure. In this article, I would like to share the simple way to load data of multiple sheets by using SSIS.
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…
This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're looking for how to monitor bandwidth using netflow or packet s…

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now