Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7846769
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T17:41:57+00:00 2026-06-02T17:41:57+00:00

I have a very simple textbox in a front end application (like php although

  • 0

I have a very simple textbox in a front end application (like php although the language doesn’t matter) and is inserting into the description column in a table in the Database defined below:

Table (ID[primary key], description[varchar(255)])

Although it will not happen often, at times there will be a need to insert more than 255 characters for one tuple. I could increase the length of the varchar but there are restrictions for the tuple size so to play it safe kept it at the recommended maximum 255.

The only way I could figure out how to do this would be to have 2 tables and split the text up into 255 character pieces. Tables defined as:

Table1 (ID[primary key]……….)

Table2 (ID, table1ID[foreign key to table 1] description[varchar(255)])

Is there a better way to achieve this?

Edit: Mysql version 5.5.11
Wasn’t aware there was a text data type. Probably new. Sounds like a type of application object but is it flexible enough to on average store 150 characters and 10% of the times store close to 5000 characters?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-02T17:42:01+00:00Added an answer on June 2, 2026 at 5:42 pm

    If using MySQL version 5.0.3 or later, you can just increase the size of your VARCHAR. According to the manual:

    Values in VARCHAR columns are variable-length strings. The length can be specified as a value from 0 to 255 before MySQL 5.0.3, and 0 to 65,535 in 5.0.3 and later versions. The effective maximum length of a VARCHAR in MySQL 5.0.3 and later is subject to the maximum row size (65,535 bytes, which is shared among all columns) and the character set used. See Section E.7.4, “Table Column-Count and Row-Size Limits”.

    To do this you would do:

    ALTER TABLE tablename MODIFY description VARCHAR(...) [NOT] NULL;
    

    Or you could use the TEXT type:

    ALTER TABLE tablename MODIFY description TEXT [NOT] NULL;
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a very simple ASP.Net page that acts as a front end for
I have very simple select like this: SELECT * FROM table WHERE column1 IN
I have a very simple WPF application in which I am using data binding
I have a very simple Java RMI Server that looks like the following: import
This could be very simple. I have a textbox on a WinForm, Text =
I have a simple html input textbox in a very simple form. the information
I have a very simple silverlight xaml page displays textbox and a button. When
I have a very simple terminal application that sens and receives characters from a
I have a very simple usercontrol, basically a textbox and a label, whose purpose
I have a very simple contact form with fields like this: <label> First Name<em>*</em>

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.