Re: syntax error in a trigger. can't find it. - Mailing list pgsql-general

From Tom Lane
Subject Re: syntax error in a trigger. can't find it.
Date
Msg-id 24806.1358029952@sss.pgh.pa.us
Whole thread Raw
In response to syntax error in a trigger. can't find it.  ("Rhys A.D. Stewart" <rhys.stewart@gmail.com>)
List pgsql-general
"Rhys A.D. Stewart" <rhys.stewart@gmail.com> writes:
> I must be very tired, very hungry or both. I'm getting a syntax error in
> the last line with the 'END;' But am clearly not seeing what the error is.
> Any help would be appreciated.

I think you need to change ELSE IF to ELSEIF.  As written you need two
END IF lines to match the two independent IFs.

I wonder whether we could get plpgsql's parser to be more helpful about
END-matching errors ... they're certainly easy ones to make.

            regards, tom lane


pgsql-general by date:

Previous
From: "Rhys A.D. Stewart"
Date:
Subject: Re: syntax error in a trigger. can't find it.
Next
From: pasilveira
Date:
Subject: pgadmin connection via tunnel and ubuntu user instead of postgres