Patent ID: 7433877

Claim:
A method of preventing text strings of disallowed lengths from being submitted to a database comprising the steps of: providing a hidden field associated with a visible user input field in a web page; receiving by said hidden field a field storage limit from a database front-end application; receiving by said front-end database application via said hidden and visible fields a user-provided string of characters intended for input into a database, said string being encoded according to a Unicode schema; for each character in said string, determining a character storage value by: (a) assigning a storage value of 2 to any character having a Unicode value of zero; (b) assigning a storage value of 1 to any character having a Unicode value between 1 and 127, inclusive; (c) assigning a storage value of 2 to any character having a Unicode value between 128 and 4095, inclusive; and (d) assigning a storage value of 3 to any character having a Unicode value of 4096 or greater; and accumulating said assigned character storage values to yield a total string storage requirement; comparing said total string storage requirement to said field storage limit received by said hidden field; responsive to said comparison finding said total string storage value is within said field storage limit submitting said user-provided string of characters to said database; responsive to said comparison finding said total string storage value exceeds said field storage limit and subsequent to user activation of a submit data command, capturing said user-provided string of characters in a administrator log; and subsequent to capturing a plurality of strings of characters in said log, adjusting said field storage limit value and an associated database field definition to reduce instances of user input exceeding database field size.