Thank you Craig, this has worked in my custom function too:
PL/pgSQL is weird, but fun :-)BEGINPERFORM check_positions(in_uid, in_gid, in_tiles);CREATE TEMP TABLE _words ON COMMIT DROP ASSELECTout_word AS word,max(out_score) AS scoreFROM check_words(in_uid, in_gid, in_tiles)GROUP BY word, gid;
I like that I can RAISE EXCEPTION in my custom function and PostgreSQL rolls everything back.
Regards
Alex