Web Application Database Field Data Sizes for User Entered DataCalculating Database Field Sizes for User Entered Data in a Typical Web Application -------------------------------------------------------------------------------------- This worksheet of examples will help you decide what sizes to make the fields in the database which supports your web application. This will also help you decide what types and sizes of form input elements to use in your Web Application. Finally, in the case of textarea elements, this will help you decide on the columns and rows attributes. The below sizes are the ones most commonly encountered and needed for all types of typical web applications which handle fields like dates and times, URLs, descriptions, titles and the like. ---------- ---- 10 Characters XxXxXxXxXx ---- 20 Characters XxXxXxXxXxXxXxXxXxXx ---- 40 Characters XxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXx ---- Common Date/Time Format (Visual Basic DateTime.Now Function Default) 3/3/2006 6:35:05 PM Minimum - 19 Characters 12/17/2005 12:32:19 PM Maximum - 22 Characters ---- 60 Characters XxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXx Reasonable maximum for a 'Short Title' or Link Text ---- 80 Characters XxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXx Reasonable maximum for an exceptional 'Long Title' or Link Text ---- 100 Characters XxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXx ---- NOTE: A typical readable 12pt Web Font of Arial/Helvetica within the horizontal space typically allotted to a web form for user data entry on a typical site width of 700 pixels comfortably allows for an 80 character width in the text input boxes. 100 is about maximum. 200 Characters at 60 width max (5 lines) ---- 200 Characters at 80 width max (3 lines) XxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXx XxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXx XxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXx ---- 200 Characters at 100 width max (2 lines) XxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXx XxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXx --- NOTE: The offical URL Specification allows for some surprizingly long URLS. In fact, because browsers must not only handle what might be a very long web address or 'path' but also a large amount of query string data appended to the end of that path - the theoretical upper limit in size for a 'URL' could well exceed 1000 characters. It is not necessary to design a URL field to handle this size unless you know for a fact you must support larger sizes and large query string data sizes. If your database will need to handle automatically extracted/generated URLs then plan to handle larger sizes. At the moment we are considering what human users will be pasting into web database text entry fields. A reasonable size to handle typical 'long' URLS is about 200 characters. 300 characters is reasonable to handle even the longest URLs you might realistically find a user trying to paste into a URL entry field. ---- 300 Characters at 80 width max (4 lines) XxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXx XxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXx XxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXx XxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXxXx -------------------------------------------------------------------------------------- |
|||||||||||||||||||||||||||||||||||||||||||||||||||||