Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 11.0.1 (Français) » SQL Anywhere Server - SQL Usage » Remote Data and Bulk Operations » Importing and exporting data » Importing data

 

Merge different table structures

Use a variation of the INSERT statement and a global temporary table to rearrange the import data to fit the table.

♦  To load data with a different structure using a global temporary table
  1. In the SQL Statements pane, create a global temporary table with a structure matching that of the input file.

    You can use the CREATE TABLE statement to create the global temporary table.

  2. Use the LOAD TABLE statement to load your data into the global temporary table.

    When you close the database connection, the data in the global temporary table disappears. However, the table definition remains. You can use it the next time you connect to the database.

  3. Use the INSERT statement with a SELECT clause to extract and summarize data from the temporary table and copy the data into one or more permanent database tables.

See also