SQL Server Performance

Importing a Range of Data from Excel file to SQL Server Table

Discussion in 'SQL Server 2005 Integration Services' started by SQLWorld, Aug 7, 2009.

  1. SQLWorld New Member

    I am new to SSIS 2005 and don't know VB & need urgent help on how to skip first few rows from the excel sheet. In the excel sheet my data starts from row number 20 & i need to import only the records below after RowNo.20. I tried using below methods after goining through solutions in google

    1) SELECT *
    FROM OPENDATASOURCE('Provider=Microsoft.Jet.OLEDB.4.0','Data Source="D:Test file1.xls";Extended Properties="Excel 8.0;HDR=No"','SELECT * FROM [Sales_Forecast$a19:au19]');
    I even tried the same using openrowset.
    2)Tried pasting the above command in Excel source under OpenRowset-->Data Acess Mode -->SQL command, but there I get error near from clause. Not able to trace it.

    It would be really helpful if you can provide me a method to do this skipping in SSIS 2005 or give me a tool within SSIS which can do this task.
  2. Madhivanan Moderator

Share This Page