Before I got to the bottom of your post, I was thinking of a whole object validation, cool. I might want to use this for my query-writer package, which has validation code for each input. Not nearly as fine grained as your idea. I also have the code for getting the postgres field length out of the db. One thing I do for all text input is check the length before trying the insert, something not supported directly by ad_page_contract filters.