Mabe you can check the length of all items.
Main Topics
Browse All TopicsI work with PL/SQL 5, and DEVELOPER 6.0. The database is ORACLE 8.1.6
I replaced all references to a particular table for a PL/SQL table defined in a package in the next manner:
type typ_reg_selex is record (clvexp char(19), ctipo number(1));
type typ_cur_selex is ref cursor return typ_reg_selex;
type typ_tab_selex is table of typ_reg_selex;
I define in the package a table of type typ_tab_selex, thus the table is in memory and I can access it both from FORMS and from database procedures. It is in a production system and works perfectly.
The problem is in REPORTS. I need to create a query about this memory table. I do it with I ref cursor query.
The sintax is:
Select * from table(my_table)
It´s compile well, but when running occurs REP-1401 error: PL/SQL fatal error. I probe anything similar in FORMS and also it compile well, but when running it, it freezes.
I have two questions??
1. Why occurs this, is it a bug problem??
2. Someone can give me another solution to generate a report from a table of this type (memory table).
thanks in advance.
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
REP-1401 occurs when trying to DIVIDE by ZERO (0). So use ZERO_DIVIDE exception handler As shown in the example below.
declare
n number;
begin
select 5/0 into n from dual;
end;
ORA-01476: divisor is equal to zero
ORA-06512: at line 4
declare
n number;
begin
select 5/0 into n from dual;
exception
when ZERO_DIVIDE then
null;
end;
PL/SQL procedure successfully completed
Business Accounts
Answer for Membership
by: alexnuijtenPosted on 2005-02-07 at 05:22:20ID: 13244057
You can't do:
Select * from table(my_table)
when my_table is a PL/SQL table, you can if it's a SQL defined Table type.
What you can do is create a User Defined Nested Table Type directly in SQL, as in:
Create type Table_type as table of varchar2(150)
This you can access as a regular database table.
If you want to create a table type based on a record, you need to create an Object in SQL.
SQL> create type record_like_ot as object
2 (id number
3 ,value varchar2(100)
4 )
5 /
Type created.
SQL> create type table_type as table of record_like_ot
2 /
Type created.
Alex
(I don't have access to a 816, but to an 817. I think differences are minimal)