Statement writing for Oracle query of user tablespace

Source: Internet
Author: User
Tags oracle cursor

How should I write statements for Oracle to query user tablespace? The following describes in detail the statements used to query user tablespace in Oracle. If you are interested in this, take a look.

The following describes how to query user tablespaces in Oracle.

◆ Oracle query user tablespace: select * from user_all_tables

◆ Oracle queries all functions and stored procedures: select * from user_source

◆ Query all Oracle users: select * from all_users.select * from dba_users

◆ Oracle view current user connection: select * from v $ Session

◆ View current user permissions in Oracle: select * from session_privs

◆ Oracle:

Select a. file_id "FileNo", a. tablespace_name
"Tablespace_name ",
A. bytes "Bytes", a. bytes-sum (nvl (B. bytes, 0) "Used ",
Sum (nvl (B. bytes, 0) "Free ",
Sum (nvl (B. bytes, 0)/a. bytes * 100 "% free"
From dba_data_files a, dba_free_space B
Where a. file_id = B. file_id (+)
Group by a. tablespace_name,
A. file_id, a. bytes order by a. tablespace_name;
 

Three methods for Oracle Authentication

Oracle Default User Password Problems

Common Oracle cursor attributes

Use instances of Oracle stored procedures

Oracle command line custom editor vi

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.