I have a huge (26GB) sqlite database that I want to import to SQL Server with SSIS.
I have everything setup correctly. Some of the data flows are working correctly a
Since the error is thrown when reading from a large dataset, try reading data by chunks, to achieve that you can follow these steps:
Int32
(@[User::RowCount]
and @[User::IncrementValue]
)Execute SQL Task
that execute a select Count(*)
command and store the Result Set into the variable @[User::RowCount]
Data flow task
ODBC Source
and OLEDB Destination
SQL Command
option and write a SELECT * FROM TABLE
query *(to retrieve metadata only`Control flow
and click on the Data flow task
and hit F4 to view the properties windowIn the properties window go to expression and Assign the following expression to [ODBC Source].[SQLCommand]
property: (for more info refer to How to pass SSIS variables in ODBC SQLCommand expression?)
"SELECT * FROM MYTABLE ORDER BY ID_COLUMN
LIMIT 500000
OFFSET " + (DT_WSTR,50)@[User::IncrementValue]"
Where MYTABLE
is the source table name, and IDCOLUMN
is your primary key or identity column.
Control Flow Screenshot