-
-
Save diegoolipa/4e5e08f99898a256b03a1c3d3daab1b1 to your computer and use it in GitHub Desktop.
Crear una base de datos y una tabla en ORACLE
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--Crear una nueva base de datos | |
--paso 01 | |
ALTER SESSION SET "_ORACLE_SCRIPT" = TRUE; | |
--paso 02 | |
CREATE USER USUARIO_MATRICULA IDENTIFIED BY "1234560" | |
DEFAULT TABLESPACE "USERS" | |
TEMPORARY TABLESPACE "TEMP"; | |
--paso 03 | |
ALTER USER USUARIO_MATRICULA QUOTA UNLIMITED ON USERS; | |
-------Diego Frank------ | |
--paso 04 | |
GRANT CREATE SESSION TO USUARIO_MATRICULA; | |
--paso 05 | |
GRANT "RESOURCE" TO USUARIO_MATRICULA; | |
--paso 06 | |
ALTER USER USUARIO_MATRICULA DEFAULT ROLE "RESOURCE"; | |
-------Diego Frank------ | |
--Crear una tabla | |
CREATE TABLE persona( | |
id_persona int primary key, | |
nombre VARCHAR2(50) not null, | |
apellido_materno VARCHAR2(50) not null, | |
apellido_paterno VARCHAR2(50) not null, | |
fecha_nacimiento DATE, | |
celular VARCHAR2(20) not null, | |
correo VARCHAR2(50), | |
direccion VARCHAR2(250), | |
id_genero int, | |
fecha_actializacion DATE, | |
fecha_registro DATE, | |
id_usuario_actializacion int, | |
id_usuario_registro int | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment