metadata driven load from excel

  • does anyone have a working example of loading from an excel file where the column count will not be the same on each import? I need to load such a file into a staging table routinely and am not familiar with creating custom components. in my scenario its fine to drop and recreate the table on each import if neccessary.

  • Is it possible for you to use an INSERT INTO statement? From BOL:

    The SELECT INTO statement creates a new table and populates it with the result set of the SELECT statement. SELECT INTO can be used to combine data from several tables or views into one table. It can also be used to create a new table that contains data selected from a linked server.

    If everything seems to be going well, you have obviously overlooked something.

    Ron

    Please help us, help you -before posting a question please read[/url]
    Before posting a performance problem please read[/url]

  • whatever will work...however, using insert into requires me to know what columns are 'in coming'. I will not know this. Is there something in your suggestion i am missing? thx for the reply

  • i just re-read your post...The select into would work...but the data is coming from excel.. its not yet in SQL server... so im thinking i need to import it first before i could do the select into...no?

  • If your Excel files are available in CSV format (in which an Excel file consisting of a single work sheet can be saved) then look at this forum posting (made today)

    http://www.sqlservercentral.com/Forums/Topic559811-149-1.aspx#bm559856

    hopefully this might point you in the direction you want to go

    If everything seems to be going well, you have obviously overlooked something.

    Ron

    Please help us, help you -before posting a question please read[/url]
    Before posting a performance problem please read[/url]

  • BitBucket...that worked great!.. very good workaround...quick to implement. Still want to get a good handle on the DTS design/runtime object model though...but for now...this will keep me going...thanks again very much. 😀

Viewing 6 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic. Login to reply