I would like to use a text field in a table and limit the size to reduce the chance of denial-of-service/buffer overflow/etc. I assume I can define table fields similar to the following
"field_name text check (len(field) < 160)" although my syntax is probably wrong. Is checking text length considered a good idea? If so, what would be a reasonable limit? I was thinking about 10 * average_field_char_length (if avg value is 16 char, set limit to 160 char). Thanks in advance for your opinions.
Thanks,
Dale
---------------------------(end of broadcast)--------------------------- TIP 4: Don't 'kill -9' the postmaster