Solved

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

Posted on 2013-05-29
4
1,560 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

NAS Cloud Backup Strategies

This article explains backup scenarios when using network storage. We review the so-called “3-2-1 strategy” and summarize the methods you can use to send NAS data to the cloud

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Lessons learned during ten years of interviewing for SQL Server Integration Services (SSIS) and other Extract-Transform-Load (ETL) contract roles and two years of staff manager interviewing contractors.
In this article we will get to know that how can we recover deleted data if it happens accidently. We really can recover deleted rows if we know the time when data is deleted by using the transaction log.
Two types of users will appreciate AOMEI Backupper Pro: 1 - Those with PCIe drives (and haven't found cloning software that works on them). 2 - Those who want a fast clone of their boot drive (no re-boots needed) and it can clone your drive wh…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

772 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