Problem: pgAdmin III query tool “IF” statement ERROR

Question : pgAdmin III query tool “IF” statement ERROR This is giving me an error in the pgAdmin II query tool. IF EXISTS(SELECT relname FROM pg_class WHERE relname = ‘Angelina_VR_Data’) THEN SELECT 2 ELSE SELECT 1 END IF; The error is: ERROR: syntax error at or near “IF” SQL state: 42601 Character: 1 Thank you in advance for your help. Please Help! This is driving me crazy!!!   Solution: pgAdmin Continue Reading →