Skip to content

G-2510: Avoid using the LONG and LONG RAW data types.

Major

Portability

Reason

long and long raw data types have been deprecated by the Oracle Database since version 8i - support might be discontinued in future Oracle Database releases.

There are many constraints to long datatypes in comparison to the lob types.

Example (bad)

1
2
3
4
5
6
7
8
declare
   l_long long;     -- violates also G-2130
   l_raw  long raw; -- violates also G-2130
begin
   do_something(l_long);
   do_something(l_raw);
end;
/

Example (good)

1
2
3
4
5
6
7
8
declare
   l_long clob;
   l_raw  blob;
begin
   do_something(l_long);
   do_something(l_raw);
end;
/