Martijn van Oosterhout <kleptog@xxxxxxxxx> writes: > The question is: does the column really need to be smallint. Yeah. Usually, declaring a function's argument as int rather than smallint is the easiest fix. We have looked into this in the past, and concluded that the negative aspects of allowing integer constants to implicitly cast to smallint parameters would outweigh the positives. As an example, such simple expressions as "2 + 2" would start to fail because it'd be unclear whether int or smallint addition is meant. (And the point isn't academic, since for example it would affect the overflow threshold.) regards, tom lane -- Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general