SSIS load multiple files with same structure but diff extension using FELC

Newbie Newbie 21 Reputation points

I have a scenario where I need to load multiple files with different file types but same structure eg: Emp_USA_012021.txt (Empid, name, desig) Empl_UK_012021.csv (Empid, name, desig) Employees_Europe_202101.xlsx (Empid, name, desig) Into sql table dbo. tbl_emp (Empid, name, design) Can this be done using FELC or I have to use individual DFTs? Please advise.

SQL Server Integration Services
SQL Server Integration Services
A Microsoft platform for building enterprise-level data integration and data transformations solutions.
2,486 questions
0 comments No comments
{count} votes

Accepted answer
  1. Monalv-MSFT 5,896 Reputation points

    Hi @Newbie Newbie ,

    We should use 2 Data Flow Tasks because we have txt, csv, xlsx files.

    We can use Foreach Loop Container to find these files.
    Then drag empty Sequence Container and 2 Data Flow Tasks.
    Set expression in Precedence Constraint between Sequence Container and 2 Data Flow Tasks.

    Please refer to the following pictures:
    Expression1: TOKEN(@[User::FileName], ".", 2)=="txt" || TOKEN(@[User::FileName], ".", 2)=="csv"
    Expression2: TOKEN(@[User::FileName], ".", 2)=="xlsx"

    Best regards,


    If the answer is helpful, please click "Accept Answer" and upvote it.

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

1 additional answer

Sort by: Most helpful
  1. Yitzhak Khabinsky 25,376 Reputation points

    @Newbie Newbie ,

    It is very easy to implement by using SSIS Foreach Loop Container
    Here is a good step-by-step example: SSIS - How To Load Multiple Files ( .txt or .csv ) To a Table With different File Names

    0 comments No comments