When I was runnig SSIS package, some Data Flow Tasks throw exception System.OutOfMemoryException
. I use Script Components in Data Flow Tasks.This script components execute queries, gets data from source database, this datas about 1,5GB , I keep this data in DataSet. Data Flow Task fail in script components PreExecute method. Here is my code block;
public override void PreExecute()
{
base.PreExecute();
connStr = this.Variables.DestinationConnectionString.ToString();
//cmParams = this.Connections.DestinationConnection;
conn = new OleDbConnection(connStr.ToString());
conn.Open();
tableAdapter = new OleDbDataAdapter("SELECT ID,OLD_ID FROM ADDRESS WHERE OLD_ID IS NOT NULL AND TENANTID=" + this.Variables.TenantID.ToString(), conn);
tableDataSet = new DataSet();
tableDataSet1 = new DataSet();
tableDataSet2 = new DataSet();
tableAdapter.Fill(tableDataSet, "Table");
tableAdapter1 = new OleDbDataAdapter("SELECT ID,OLD_ID FROM COMPANY WHERE OLD_ID IS NOT NULL AND TENANTID=" + this.Variables.TenantID.ToString(), conn);
tableAdapter1.Fill(tableDataSet1, "Table1");
tableAdapter2 = new OleDbDataAdapter("SELECT ID,OLD_ID FROM ENTITY WHERE OLD_ID IS NOT NULL AND TENANTID=" + this.Variables.TenantID.ToString(), conn);
tableAdapter2.Fill(tableDataSet2, "Table2");
}
My package size is 4069KB.
Data Flow Task max buffer size: 20MB
Data Flow Task max buffer max rows : 10000
Can any one help me about this exception?