Example code for creating a tablespace in Oracle

Source: Internet
Author: User

The following articles describe how to create a table space in Oracle and how to create a user's code description to analyze how to create a table space in Oracle and how to create a user's actual application. The following is a detailed description of the database, I hope you will understand this article after reading it.

Create temporary tablespace

 
 
  1. create temporary tablespace test_temp   
  2. tempfile 'E:\Oracle\product\10.2.0\oradata\testserver\test_temp01.dbf'   
  3. size 32m   
  4. autoextend on   
  5. next 32m maxsize 2048m   
  6. extent management local;  

Create a data table space

 
 
  1. create tablespace test_data   
  2. logging   
  3. datafile 'E:\Oracle\product\10.2.0\oradata\testserver\test_data01.dbf'   
  4. size 32m   
  5. autoextend on   
  6. next 32m maxsize 2048m   
  7. extent management local;  

Create a user and specify a tablespace in Oracle

 
 
  1. create user username identified by password   
  2. default tablespace test_data   
  3. temporary tablespace test_temp;  

Grant permissions to users

 
 
  1. grant connect,resource to username; 

The preceding content describes how to create a tablespace and user-related code in Oracle, hoping to help you in this aspect.

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.