Have you tried getting a profile of what exactly PostgreSQL is doing
that takes so long when creating a temp table?

Nope, I'm not proficient in the use of these tools (I stopped using C some time ago).

BTW, I suspect catalogs might be the answer,

        Probably, because :

        - Temp tables don't use fsync (I hope)
        - Catalogs do
        - fsync=off makes COMMIT fast
        - fsync=on makes COMMIT slow
- fsync=on and using ANALYZE makes COMMIT slower (more updates to the catalogs I guess)

which is why Oracle has you
define a temp table once (which does all the work of putting it in the
catalog) and then you just use it accordingly in each individual
session.

        Interesting (except for the ANALYZE bit...)



---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?

              http://archives.postgresql.org

Reply via email to