I am executing PostgreSQL functions to update a table which has a huge amount of data and the update happens for about 100000 records everyday. During the update I get an error saying:
"could not write to hash-join temporary file: No space left on device"
I have not really been able to get something useful to overcome this error. I got something where it says to SET a temporary table spaces. But I was not able to find how do I create a temporary table space where the data will be stored during the executing of the update procedure.
SQL> create tablespace temp_tbs location '/some/big/disk';
temp_tablespaces = 'temp_tbs'
in postgresql.conf.select pg_reload_conf();