Useful shortcuts for vi editor

Tuesday, 28 November 2017

How to show line number in SQL Developer?

Tools -> Preferences -> Code Editor -> Line Gutter -> Activate "Show Line Numbers" -> OK

Wednesday, 8 November 2017

How to export/set ORACLE_SID?

Linux
export variable
$ export ORACLE_SID=XE

check variable
$ echo $ORACLE_SID

Windows
set variable
> set ORACLE_SID=XE

check variable
> echo %ORACLE_SID%

Friday, 3 November 2017

ORA-01950 Solution

Action
SQL> CREATE TABLE HR2.EMPLOYEES_NEW AS SELECT * FROM HR.EMPLOYEES;

Error
ORA-01950: no privileges on tablespace 'USERS'

Solution I
SQL> ALTER USER HR2 QUOTA 1024M ON USERS:

Solution II
SQL> GRANT UNLIMITED TABLESPACE TO HR2;