File Connection
File
connection is used to make connection to any type of file, be it excel, flat,
image, any type. Even we can use it to make connection to a folder instead of
file. If the file or folder doesn’t exist then new folder or file can also be
created.
File
can also be created dynamically by providing expression in the properties of
file connection manager.
Use in real time scenario:
Sometime
it happens, we need to run our package on a scheduled basis say daily. Also, we
need to save the result of the package in some folder to do analysis on the
results generated.
The
solution is to create the file dynamically, that is the file name will be
generated on the basis of some system or user variable. It will be different
each day, if we also use date in the file name. This can be done by setting the
expression in file connection properties as shown below.
For
creating the connection, go to the Connection Manager and select File
Connection.
Go to
the properties of File Connection Manager, and then go to expression. It will
open a Property Expression Editor, where we can set property like connection
string etc.
For all other connection click on below links,
OleDB and ADO.Net Connection
Flat File Connection
Connection from Data source
New Connection
No comments:
Post a Comment