16

In SQL Server 2005, Import Data (SSIS), my desire is to import a text file and have it append to an existing table. The first time through the wizard on the Column Mappings step I swear the Append rows to the destination table radio button was enabled. But, now, it's disabled (grey) and even re-starting the wizard won't cause it to re-enable.

Is there some secret/magic I don't know about? How do I get that option to re-enable so that I can append (rather than Create destination table)?

Pete Alvin
  • 4,206
  • 8
  • 34
  • 53

3 Answers3

32

I know what you're missing... because I once missed it too!

From the screen, "Select Source Tables and Views",
there is a "destination" drop-down menu on the right side.

Select your table from this drop-down,
then click on the "Edit Mappings" button.

Now the append option will be enabled!

David
  • 68,722
  • 16
  • 125
  • 165
Indy
  • 321
  • 3
  • 2
  • 3
    Just what I was missing too. Thanks! – anton.burger Oct 15 '12 at 09:28
  • Same issue here. I suppose one idea, a little crazy but hear me out. What if, it's a big IF, the tool had a check if the destination has a matching schema.table as the source and it pre-populates the destination with the matching value. Nah nvm. Stupid – DontFretBrett Oct 09 '20 at 16:11
10

In my experience, if the table you're importing into doesn't exist at the time you're going through the "SSIS Import and Export Wizard", you won't have the option to Append; if the table does exist at the time you're going through the wizard, the option is available.

If you do choose the "Create table" option, the wizard just builds the SSIS package with an Execute SQL task that builds the table prior to the data flow that loads the data. So, you can always just remove the task in the resulting package and you'll get "Append" by default.

Patrick Marchand
  • 3,275
  • 18
  • 13
  • 1
    This was the clue! In my case the table names had different cases. – jlo-gmail Dec 07 '15 at 23:11
  • Thanks! This was my issue. "the table you're importing into doesn't exist at the time". I didn't refresh sql server after I used code first migrations with EF6 so my tables didn't exist yet. – CareTaker22 Oct 17 '16 at 10:28
2

The name of the table must be preceded with schema name ("dbo."). Otherwise the wizard didn't find it in my case.

Ondra
  • 21
  • 1