|
Why would this crash my server: msg#00259db.postgresql.novice
Hi all I've been playing round for a week or so now trying to master the elusive secrets of passing sets of records around in postgres. Having made a little progress, I thought I'd try using cursors - I didn't get very far, but I did bring my machine to its knees and kill the postgres server (on the same machine). Here's what I did, I'm wondering what needs changing: -- Here is my table glenn=# select * from zz; a | b ---+--- 1 | 0 2 | 0 3 | 0 4 | 2 5 | 2 6 | 1 7 | 4 8 | 4 9 | 7 (9 rows) -- Here is my experimental function create or replace function zz_dump() returns setof zz as ' declare thiscur refcursor; zz_tmp zz%rowtype ; begin open thiscur for select a, b from zz; fetch thiscur into zz_tmp ; return zz_tmp; end;' language 'plpgsql'; --Heres the result, which comes after 5 min of hdd light thrashing, capslock light doesn't respond and gui completely freezes. Interesting thing is that after this executes, the gnome resources panel shows that the amount of physical memory in use has halved. i.e. first time 95%->47%, 2nd time 47%->21% thanks for _any_ help Glenn ---------------------------(end of broadcast)--------------------------- TIP 2: you can get off all lists at once with the unregister command (send "unregister YourEmailAddressHere" to majordomo@xxxxxxxxxxxxxx) |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Re: User Problem In PostgreSQL on Mac OS X: 00259, Robert Prather |
|---|---|
| Next by Date: | Substring & escape Character: 00259, Michael Weaver |
| Previous by Thread: | User Problem In PostgreSQL on Mac OS Xi: 00259, Robert Prather |
| Next by Thread: | Re: Why would this crash my server: 00259, glenn |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |