|
If you've set a character limit in the PHP fields within your script, then maxlength of characters inserted into your db will be ONLY what you have set in your php form fields as maxlength.
Example, if I have a field called `tomorrow` and set the maxlength in my form at 200 characters but I have defined the `tomorrow` field in my db as varchar(255) then the MAX data length that will be inserted into the field via my form will be *only* 200 characters (taken from my form maxlength) regardless of the amount of characters I have defined for field length in the db.
Generally, things like title, keywords, descriptions would all be varchar(255) and some field that would contain more information (larger amounts) like `details` would be set as text.
The maxlength of an index is 255.
You can add as many fields to an index as you want, as long as the length of field given to each (for the index only) doesn't equal more than 255.
Divide it up between the number of fields that you have and set each one to that number length.
Example, 5 fields in index using 255 maxlength on index means each field in the index can use a maxlength character set of 51 characters.
As long as the length of field is greater than 15 for each field added to the index, your index should be fine.
Are you using MyISAM?
|