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

  • Home
  • SEARCH
  • 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 4270716
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 21, 20262026-05-21T07:20:38+00:00 2026-05-21T07:20:38+00:00

I have a situation where I have to create tables dynamically. Depending on some

  • 0

I have a situation where I have to create tables dynamically. Depending on some criteria I am going to vary the size of the columns of a particular table.
For that purpose I need to calculate the size of one row.

e.g.
If I am going to create a following table

CREATE TABLE sample(id int, name varchar(30));

so that formula would give me the size of a single row for the table above considering all overheads for storing a row in a mysql table.

Is possible to do so and Is it feasible to do so?

  • 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-05-21T07:20:39+00:00Added an answer on May 21, 2026 at 7:20 am

    It depends on the storage engine you use and the row format chosen for that table, and also your indexes. But it is not a very useful information.

    Edit:

    I suggest going against normalization only when you know exactly what you’re doing. A DBMS is created to deal with large amount of data. You probably don’t need to serialize your strctured data into a single field.

    Keep in mind that your application layer then has to tokenie (or worse) the serialized field data to get the original meaning back, which has certainly larger overhead than getting the data already in a structured form, from the DB.

    The only exeption I can think of is a client-heavy architcture, when moving processing to the client side actually takes burden off the server, and you would serialize our data anyway for the sake of the transfer. – In server-side code (like php) it is not a good practive to save serialized stye data into the DB.

    (Though, using php’s built in serialization may be a good idea in some cases. Your current project does not seem to benefit from it.)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a table that, some of its columns are unknown at compile time.
Here is my situation: I have one table that contains a list of drugs
Here's the situation: I have a menu that needs to be created dynamically from
Suppose I have the following tables: CREATE TABLE Game ( GameID INT UNSIGNED NOT
I have this situation: I have to create a dataset that takes all data
My situation is i have four tables Patient, Receipt, Clinic and Laboratory. CREATE DATABASE
I have a script that appends some rows to a table. One of the
Here is the situation that I'm facing: I have two tables A and B.
I have a situation where I want to create a signature of a data
I have a simulation that reads large binary data files that we create (10s

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.