From: | chinchu2005 <chinchu2005(at)gmail(dot)com> |
---|---|
To: | pgsql-general(at)postgresql(dot)org |
Subject: | ERROR: array subscript out of range |
Date: | 2009-04-10 18:20:27 |
Message-ID: | 22992481.post@talk.nabble.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Hello all,
Need ur help.I dont know wats wrong with the following fucntion.
create or replace function twoarray() returns setof integer as
'
declare
i integer;
j integer;
a integer[][];
begin
for i in 1..10 loop
for j in 1..2 loop
a[i][j]:=i*j;
return next a[i][j];
end loop;
end loop;
return;
end;
'
language 'plpgsql';
when i execute the following statement i get an error saying 'array
subscript out of range'
select * from twoarray();
ERROR: array subscript out of range
CONTEXT: PL/pgSQL function "twoarray" line 8 at assignment
Help me,please
--
View this message in context: http://www.nabble.com/ERROR%3A-array-subscript-out-of-range-tp22992481p22992481.html
Sent from the PostgreSQL - general mailing list archive at Nabble.com.
From | Date | Subject | |
---|---|---|---|
Next Message | Bruce Momjian | 2009-04-10 19:23:56 | Re: Multiple character encodings within a single database/table? |
Previous Message | Pedro Doria Meunier | 2009-04-10 18:05:27 | Internationalization |