Search Postgresql Archives

explain analyzing a query inside an sql stored procedure

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

Is there any easy way to explain analyze a query, which is inside an sql stored procedure? I could of course copy the query out of the procedure, and explain analyze it but this is a slower process. I would do this with a lot of procedures, that's why it should be fast.

create function myquery() returns setof record as $$
   select * from mytable; --this is a set returning query
$$ language sql;

explain analyze select * from myquery();

For me this shows function scan, and not the plan of the query itself.

Best Regards,
Otto



---------------------------(end of broadcast)---------------------------
TIP 1: if posting/reading through Usenet, please send an appropriate
      subscribe-nomail command to majordomo@xxxxxxxxxxxxxx so that your
      message can get through to the mailing list cleanly

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux