ORA-01467 Sort key too long on Interactive Report
dsykesMay 15 2008 — edited Sep 12 2008I am getting this runtime error on my interactive report (IR) (select * from tablename).
The table has a high number (>20) varchar2(4000) columns. I have
searched this forum and found no ORA-01467 error related
threads regarding IR. I have read this asktom thread:
http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:508222056084
to see how it might apply here.
I am running apex 3.1 on 9.2.0.8 EE with an 8K block size. on solaris. If I reduce the number of varchar2(4000) columns the error goes away. I am trying to deduce at what point the I will hit the error based on my table design (or aggregate length of
all columns in the table or some other metric). I don't know what group-bys or distincts IR is doing behind the scenes (and I don't see any place with APEX to control this). Try this:
1) create this table:
drop table testtab;
create table testtab (
f1 varchar2(4000),
f2 varchar2(4000),
f3 varchar2(4000),
f4 varchar2(4000),
f5 varchar2(4000),
f6 varchar2(4000),
f7 varchar2(4000),
f8 varchar2(4000),
f9 varchar2(4000),
f10 varchar2(4000),
f11 varchar2(4000),
f12 varchar2(4000),
f13 varchar2(4000),
f14 varchar2(4000),
f15 varchar2(4000),
f16 varchar2(4000),
f17 varchar2(4000),
f18 varchar2(4000),
f19 varchar2(4000),
f20 varchar2(4000)
);
2) Create an interactive report select * from testtab. Run it . Get the error.
3) Eliminate columns f11-f20 (drop and recreate table).
4) Re-gen interactive report (edit the definition and Apply Changes) and run with no errors.
Dave