SQL Query

  • We have imported tables from Excel and Access and now want to insert date from temporary import tables to our DB. We have to import data of columns A and B from one source and column C with data of another one.

    eg: EmployeeName and Address from Table1 and the fees from Table2

    INSERT INTO staff.EmployeeName, staff.Adresse

    SELECT EmployeeName, Address FROM Table1

    this does not work, cause insert-select does not support column selection within the insert statement.

    Any hints?

  • HI,

    correct syntax is:

    INSERT INTO staff (staff.EmployeeName, staff.Adresse)

    SELECT EmployeeName, Address FROM Table1

    bye Antonio

Viewing 2 posts - 1 through 1 (of 1 total)

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