SSIS – using connection object inside Script Component

There might be a situation where you need to use a connection object inside an Script Component. The scenario can be you need to Query a table based on some parameters during the transformation and use that result to do some process and so forth.

To accomplish this, you can type cast the connection object(referenced in script component) to the corresponding .NET connection (oledb or or you can use the connection string property and use it to establish a connection to the database.

I find using the connection string method to be more safe and reliable, rather than type convertion. In other words programming Convenience huh  🙂

Create a Simple SSIS package that reads data from AdventureWorks database.











In the script component reference oledb connection.

Use this connection string inside the Script component as shown below.

Hope this helps.


Procedure to Add App Pool Identity to SQL Server db_owner Role

When you host a WCF service in IIS and if the service access SQL Server database, then you need to add the Application pool identity used by the WCF Service in to the db_owner of the Database. If you dont add the app pool identity then the service will not return any records from the database.

To add the app pool identity to db_owner role follow the steps as shown below. The following screen shots are for SQL Server 2008 and the WCF service uses ASP.NET v4.0 application pool.


Bought new laptop – Dell XPS 15

I’ve been using inspiron dual core with 2gb ram for the past 3 years. Really thinking about getting a good laptop as the hardware requirements are increased considerally with every release of Microsoft software like sharepoint 2010,  visual studio 2010, sqlserver 2008 etc.,,

Well well well happy to grab the EOFS deals from dell australia and recently bought DELL XPS 15 from JB Hifi store in Carindale, Qld, Australia. It cost me around $1100 + $99 for the windows 7 professional upgrade…

Intel core i7 2nd Generation 2630QM @ 2.00GHZ
Nvidia 1GB Graphics
Upgraded to windows 7 professional 64 bit
JBL Speakers.

So far very happy with the laptop… pretty good performance… will install other apps and update…