importing data into Many-Many related tables

  • I have 3 tables with the following structure:

    RatesTable

    RatesID int Identity PK

    RateCode varchar

    Rates money

    State varchar

    Territory varchar

    FormsTable

    FormsID int indentity PK

    FormName varchar

    FormDesc Varchar

    Rates_FormsTable

    RatesID

    FormsID

    I have an excel spreadsheet with the following sample data I need to import into those tables:

    RateCode Form1 Form2 Form3 Form4 Rate State Territory

    95154 G755 U75 $14.82 CA 2

    95154 G755 U75 U076 $8.65 CA 3

    95154 G755 $6.55 TX Central

    91801 U75 $2.55 NV 1

    How do I go about importing this data into the tables I have? Just learning about many-many relationships and can't quite get my head around how to get the correct info into the correct tables.

    Thanks in advance!

  • This was removed by the editor as SPAM

  • I like the solution above. It's much easier to work with this data inside SQL Server than it is during the import.

  • Sorry this took so long, but Thank You. This worked great!

Viewing 4 posts - 1 through 3 (of 3 total)

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