Oracle notes (III), SQL * Plus

Source: Internet
Author: User

1. Account Logon
C: \> sqlplus "sys/love2you as sysdba"

C: \> sqlplus/nolog
SQL> connect sys/love2you as sysdba

2. Start and close the instance

● SQL> startup
Start the instance, open the control file, and open the data file

● SQL> startup Mount
Start the instance and open the control file

● SQL> startup nomount
Start an instance

● SQL> shutdown immediate
Force all users to disconnect and shut down the server after executing the current SQL statement.

● SQL> Shutdown
Wait for all users to disconnect and close the server.

3. SQL * Plus execution plan
Oracle only schedules one query plan in the form of substitution variables to improve statement execution efficiency.

SQL> select * from Dept where deptno = & TT
Enter value for TT: 10
....

SQL> select * from Dept where deptno = & TT
Enter value for TT: 20

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.