dustov <dustov(at)gmail(dot)com> writes:
> PGError: ERROR: input is out of range
I see no such error string in the current sources ... what Postgres
version are you using?
If you set "\set VERBOSITY verbose" in psql before trying the query,
you should get some extra info about where the message is coming from.
regards, tom lane