I have a complicated Pl/PGsql proc that takes 5 seconds to run and Im looking for a way to measure internal timing so I can figure out what is slow.
I tried doing variations of
v_now := now(); raise notice ''timestamp %'', v_now;
but postgres tells the proc that now() is always the time when it was invoked.
Can anywone suggest a way to measure timing inside of pl/pgsql procs or do I just need to crawl through all the pieces by hand myself?
thanks,
Carl
Request notifications