Oracle creates table spaces and grants permissions to users ____oracle

Source: Internet
Author: User
--Create TABLE space-syntax: create tablespace table space name datafile ' path ' size 100M [aotuextend to];
   
 Create tablespace myspace datafile ' d:/myspace/myspace.dbf ' size 100M autoextend on;
    --Renaming Tablespace--syntax: Alter tablespace old name rename to new name;
    
Alter tablespace newspace Rename to MySpace; --Delete tablespace--[including contents cascade constraints] and delete the contained data and constraints-syntax: Drop tablespace tablespace name [including contents Cascade C
    Onstraints];
    
    
Drop tablespace MySpace including contents cascade constraints;
   --Create a temporary tablespace-syntax: Create temporary tablespace temporary table space name tempfile ' path ' size 100M;
   
Create temporary tablespace mytempspace tempfile ' d:/myspace/mytempspace.dbf ' size 20M; --Create a user and specify tablespace and temp table spaces create user Lisi identified by Lisi default tablespace myspace temporary tablespace myt
   
Empspace;
    --A new user with no permissions, no connection--give users permission--permission to connect to the database grant create session to Lisi;
    --Create TABLE permissions grant create table to Lisi; --Permissions to use tablespace Grant unlimited TABLESPACE to Lisi; --Create a user table created table Tb_user (u_id number primary key, U_name varchar2 (), U_pass varchar2 (20));


---view table space

SELECT * from V$tablespace;



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.