Oracle questions: 10 questions every day (10)

Source: Internet
Author: User

91. How to estimate the number of I/O executed by SQL?

SQL> set autotrace on;

SQL> select * from table;

Or

SQL> select * from V $ filestat;

I/O count can be viewed

92. How can I change the field size in sqlplus?

Alter table table_name modify (field_name varchar2 (100 ));

It cannot be changed to a large row (unless it is empty)

93. How do I query data of a certain day?

Select * From table_name where trunc (Date Field) = to_date ('2017-05-02 ', 'yyyy-mm-dd ');

94. How do I insert the SQL statement into the year-round date?

Create Table bsyear (d date );
Insert into bsyear
Select to_date ('20140901', 'yyyymmdd') + rownum-1
From all_objects
Where rownum <= to_char (to_date ('201312', 'yyyymmdd'), 'ddd ');

95. If you want to modify the table name?

Alter table old_table_name Rename to new_table_name;

96. How to obtain the return status value of the command?

Sqlcode = 0

97. How do I know the user's permissions?

Select * From dba_sys_privs;

98. What is the difference between the Oracle9i downloaded from the internet and the standard edition sold on the market?

In terms of functions, there is no difference, except that Oracle has clearly stipulated that Oracle products downloaded from the website cannot be used for commercial purposes, or else infringement.

99. How can I determine whether the database is running in archive mode or non-archive mode?

Go to dbastudio, and choose history> database> archive.

100. SQL> what is the difference between startup pfile and ifile and spfiled?

Pfile is a traditional Oracle initialization parameter file in text format. Ifile is similar to the include in C language and is used to introduce another file into spfile. It is a new and default parameter file in 9i. After the binary format is startup, only pfile can be connected.

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.