Alvaro Herrera <alvherre@alvh.no-ip.org> writes:
>> What does "really be two messages" mean?
> I mean you should do this:
> if (enabled)
> {
> if (changed == 1)
> ereport("One trigger on %s enabled")
> else
> ereport("%d triggers on %d enabled")
> }
This isn't really a gain in localizability because it assumes that there
are only singular and plural forms. I do agree that plugging words like
"enabled" or "disabled" into a string is not good style. Please read
the message style guidelines at
http://developer.postgresql.org/docs/postgres/error-style-guide.html
particularly the section about writing localization-friendly messages
http://developer.postgresql.org/docs/postgres/nls-programmer.html#NLS-GUIDELINES
regards, tom lane