I want to verify the syntax of files containing sql queries before they can be committed in my CVS project.
In order to do that, I have a commitinfo script, but I h
You could just wrap it in SELECT 1 ( ) AS a WHERE 1 = 0;
SELECT 1 ( ) AS a WHERE 1 = 0;
It'll fail on validation but it won't actually execute. Here's an example query plan:
Result (cost=0.00..0.01 rows=1 width=0) One-Time Filter: false