From: | Jean-Paul ARGUDO <jean-paul(dot)argudo(at)idealx(dot)com> |
---|---|
To: | pgsql-bugs(at)postgresql(dot)org |
Cc: | jean-paul(dot)argudo(at)idealx(dot)com, sdinot(at)idealx(dot)com, dbarth(at)idealx(dot)com |
Subject: | function tree_level(varchar) (from OpenACS) no longer work under 7.2 |
Date: | 2002-02-27 08:07:32 |
Message-ID: | 20020227090732.A10722@singer.ird.idealx.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs |
Hi all,
Testing a port from Oracle to PG 7.1.3. onto PG 7.2 has error trying to use the
following function (frop OpenACS, to port connect by Oracle statments under PG):
create function tree_level(varchar) returns integer as '
declare
inkey alias for $1;
cnt integer default 0;
begin
for i in 1..length(inkey) LOOP
if substr(inkey,i,1) = ''/'' then
cnt := cnt + 1;
end if;
end LOOP;
return cnt;
end;' language 'plpgsql';
example:
dbks=# select tree_level(t01_tree_sortkey) from t01_20011231 limit 10;
ERROR: SearchSysCache: Bad cache id 27
I found the SearchSysCache() function in tools/cache in the PG srcs. Readding
the code, I tought about corruption problems on the database. I made a
vacuum --analyze dbks, hopping this would "repair" the DB.
But this still not works. So I'm a bit confused. What's wrong?
Thanks in advance and best regards.
--
Jean-Paul ARGUDO
From | Date | Subject | |
---|---|---|---|
Next Message | Radek Hrabčák | 2002-02-27 11:16:45 | SELECT statement causing terminating the backend |
Previous Message | Bruce Momjian | 2002-02-27 03:09:32 | Re: COPY FROM is not 8bit clean |