My Oracle Support Banner

DBMS_COMPRESSION.GET_COMPRESSION_RATIO Fails With ORA-00933 - ORA-06512 (Doc ID 1493289.1)

Last updated on MARCH 27, 2014

Applies to:

Oracle Server - Enterprise Edition - Version and later
Information in this document applies to any platform.


On production database version, when checking a table for possbile compression ratio the following statement fails as below.

ORA-00933: SQL-Befehl wurde nicht korrekt beendet
ORA-06512: in "SYS.PRVT_COMPRESSION", Zeile 776
ORA-06512: in "SYS.DBMS_COMPRESSION", Zeile 214
ORA-06512: in Zeile 10

 v_blkcnt_cmp pls_integer;
 v_blkcnt_uncmp pls_integer;
 v_row_cmp pls_integer;
 v_row_uncmp pls_integer;
 v_cmp_ratio number;
 V_COMPTYPE_STR varchar2(60);
 scratchtbsname => 'TST_DATA',
 ownname => 'TEST',
 tabname => 'TEST_TA',
 partname => NULL,
 comptype => 2,
 blkcnt_cmp => v_blkcnt_cmp,
 blkcnt_uncmp => v_blkcnt_uncmp,
 row_cmp => v_row_cmp,
 row_uncmp => v_row_uncmp,
 cmp_ratio => v_cmp_ratio,
 dbms_output.put_line('Estimated Compression Ratio: '||to_char(v_cmp_ratio));
 dbms_output.put_line('Blocks used by compressed sample: '||to_char(v_blkcnt_cmp));
 dbms_output.put_line('Blocks used by uncompressed sample: '||to_char(v_blkcnt_uncmp));


To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!

My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.