ycliper

Популярное

Музыка Кино и Анимация Автомобили Животные Спорт Путешествия Игры Юмор

Интересные видео

2025 Сериалы Трейлеры Новости Как сделать Видеоуроки Diy своими руками

Топ запросов

смотреть а4 schoolboy runaway турецкий сериал смотреть мультфильмы эдисон
Скачать

36 | How to Create New User & Grant Privileges and Managing Roles | Oracle PL/SQL Programming

merge record data in table oracle sql

commit

rollback

savepoint

projection

joining

how to use select statement in oracle sql

dql

ascending order sql

descending order sql

column filter in sql

Character Function

Numeric or Number Function

Date Function

Conversion Function

General Function

lower

upper

length

rpad

lpad

substr

replace

instr

ltrim

rtrim

trim

translate

NVL

NVL2

COALESCE

create new user oracle sql

grant privileges to users

manage roles to users oracle sql

Автор: Book Of Infinity

Загружено: 2022-06-19

Просмотров: 213

Описание: CREATE USER
Purpose

Use the CREATE USER statement to create and configure a database user, which is an account through which you can log in to the database, and to establish the means by which Oracle Database permits access by the user.

You can enable a user to connect to the database through a proxy application or application server. For syntax and discussion, refer to ALTER USER.

Prerequisites

You must have the CREATE USER system privilege. When you create a user with the CREATE USER statement, the user's privilege domain is empty. To log on to Oracle Database, a user must have the CREATE SESSION system privilege. Therefore, after creating a user, you should grant the user at least the CREATE SESSION system privilege. Please refer to GRANT for more information.

Syntax

create_user::=
Semantics

user

Specify the name of the user to be created. This name can contain only characters from your database character set and must follow the rules described in the section "Schema Object Naming Rules". Oracle recommends that the user name contain at least one single-byte character regardless of whether the database character set also contains multibyte characters.

IDENTIFIED Clause

The IDENTIFIED clause lets you indicate how Oracle Database authenticates the user.

BY password

The BY password clause lets you creates a local user and indicates that the user must specify password to log on to the database. Passwords can contain only single-byte characters from your database character set regardless of whether the character set also contains multibyte characters.

Passwords must follow the rules described in the section "Schema Object Naming Rules", unless you are using the Oracle Database password complexity verification routine. That routine requires a more complex combination of characters than the normal naming rules permit. You implement this routine with the UTLPWDMG.SQL script, which is further described in Oracle Database Security Guide.

First you’ll need login as system or sys. Once you’re in, the basic create user command is:

create user username identified by "password";
So to create the user data_owner with the password Supersecurepassword!, use:

create user data_owner identified by "Supersecurepassword!";
Now you’ve got your user. The next step is to connect to it. But try to do so and you’ll hit:

conn data_owner/Supersecurepassword!

ORA-01045: user DATA_OWNER lacks CREATE SESSION privilege; logon denied
What’s going on?

The problem is you haven’t given the user any permissions! By default a database user has no privileges. Not even to connect.

Granting User Privileges
You give permissions with the grant command. For system privileges this takes the form:

grant privilege to user
To allow your user to login, you need to give it the create session privilege. Let’s do that:

grant create session to data_owner;
There are a whole raft of other permissions you can give your users. And some rather powerful roles that grant them all.

So what should you enable?

At this point, keen to get developing, you may be tempted to give your user a bucket of powerful permissions.

Before you do, remember a key security concept:

The Principle of Least Privilege.

Only give your users the smallest set of privileges they need to do their job. For a basic data schema that’s simply create table:

grant create table to data_owner;
This allows you to make tables. As well as indexes and constraints on them. But critically, not store data in them!

Which is could lead to embarrassing errors when deploy your brand new application:

conn data_owner /Supersecurepassword!

36 | How to Create New User & Provide Privileges and Roles in ORACLE SQL | Oracle PL/SQL Programming

36 | How to Create New User & Grant Privileges and Managing Roles | Oracle PL/SQL Programming

#create_new_user #grant_privileges #managing_role

Не удается загрузить Youtube-плеер. Проверьте блокировку Youtube в вашей сети.
Повторяем попытку...
36 | How to Create New User & Grant Privileges and Managing Roles | Oracle PL/SQL Programming

Поделиться в:

Доступные форматы для скачивания:

Скачать видео

  • Информация по загрузке:

Скачать аудио

Похожие видео

37 | JOIN in ORACLE SQL | PROPRIETARY | COMPLIANT JOIN | Oracle PL/SQL Programming

37 | JOIN in ORACLE SQL | PROPRIETARY | COMPLIANT JOIN | Oracle PL/SQL Programming

Отмена рейсов, интернета и навигации | Как живёт Россия в условиях войны (English sub) @Max_Katz

Отмена рейсов, интернета и навигации | Как живёт Россия в условиях войны (English sub) @Max_Katz

C++ 26 is Complete!

C++ 26 is Complete!

Конец империи. Почему Ильхам Алиев пошел против Путина

Конец империи. Почему Ильхам Алиев пошел против Путина

Россия стягивает войска / Президент выступил с заявлением

Россия стягивает войска / Президент выступил с заявлением

Я СДЕЛАЛ ИДЕАЛЬНЫЙ ШАР ИЗ ОБЫЧНОЙ ЗЕМЛИ - ДРЕВНЯЯ ЯПОНСКАЯ ТЕХНИКА

Я СДЕЛАЛ ИДЕАЛЬНЫЙ ШАР ИЗ ОБЫЧНОЙ ЗЕМЛИ - ДРЕВНЯЯ ЯПОНСКАЯ ТЕХНИКА

Docker CLI Commands Every DevOps Engineer Should Know! 🔧🔥#docker #commandstutorial

Docker CLI Commands Every DevOps Engineer Should Know! 🔧🔥#docker #commandstutorial

Google Deepmind's VIDEOGAME AGI? (the REAL reason for VEO 3)

Google Deepmind's VIDEOGAME AGI? (the REAL reason for VEO 3)

Японец по цене ВАЗа! Оживляем пацанскую мечту :)

Японец по цене ВАЗа! Оживляем пацанскую мечту :)

⚡ ГУР: Россия перебрасывает войска в Армению. Что задумал Путин?

⚡ ГУР: Россия перебрасывает войска в Армению. Что задумал Путин?

© 2025 ycliper. Все права защищены.



  • Контакты
  • О нас
  • Политика конфиденциальности



Контакты для правообладателей: [email protected]