James McManus <jmpmcma...@gmail.com> writes: > However, when I try and use EXECUTE in the mvtgeom AS section of the script > I get a syntax error on EXECUTE:
You need to convert the *entire* query into a string and apply EXECUTE to that. You can't use EXECUTE as a part of a query. regards, tom lane