0

I would like to import a csv file into an empty table in SQL Server Developer 2016, using Task Wizard. I know with BULK INSERT there are options to specify firstrow and lastrow; does Import Wizard have a similar feature?

asked Jul 12, 2017 at 14:44
3
  • 1
    Pretty sure there is an option to skip x rows....probably the first x, not from say 100-200.. Commented Jul 12, 2017 at 15:05
  • Right. I was wondering if I was missing s range option. Oh well. Commented Jul 12, 2017 at 18:48
  • Did you get what you needed? Commented Jul 17, 2017 at 19:54

2 Answers 2

0

The wizard only has the option to skip the first x rows...more complex than that would need to be a regular SSIS package, or some pre-processing of the file before the wizard picks it up.

Alternatively, import the whole file to a staging table and then trash the rows you don't need, or push the ones you do want into the correct destination table in a T-SQL statement.

answered Jul 13, 2017 at 1:09
0

Just as I suspected, task wizard does not have the ability to select import range. I ended up using bulk import and using the FIRST_ROW and LAST_ROW options.

answered Jul 31, 2017 at 16:09

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.