Oracle: Bulk import of data from SQL files

Source: Internet
Author: User
  1. Enter the DOS interface.
  2. Enter the SQL file directory.
  3. Run Sqlplus,c:\sql>sqlplus user_name/[email protected]_service_name at the command prompt
  4. Specify the SQL execution log file, log filename arbitrary, but must be a log suffix name: Sql>spool e:\temp\a.log
  5. Create a batch execution file. If you want to execute multiple SQL files in bulk, you can create a list file, such as List.sql, which lists each SQL file, starting with @@ 开头 for example
    @@a.sql;
    @@b.sql;
  6. Call the bulk Execute file,sql> @list. sql
  7. If only a single SQL file is executed, it can be called directly, Sql>@@a.sql
  8. After the SQL command finishes executing, look at the log file to see if there is an "error".
  9. If there is no error, call Sql>spool off
  10. Exit Sqlplus, the data will not be actually written after exiting Oracle,sql>exit

Note that the first line of the SQL command in the SQL file must end with a semicolon.

Oracle: Bulk import of data from SQL files

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.