I was about to import a .sql file into a database. The size of the sql file is 35GB, and the available size in our server is 10gb. At this point, can I import the sql file into the database? I'm not sure whether it can be done.

My question here is how much space is required to import a 32GB sql file into the database?

closed as off-topic by Max Vernon, RLF, RolandoMySQLDBA, Paul White, ypercubeᵀᴹ Jan 10 '15 at 12:38

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Too localized - this could be because your code has a typo, basic error, or is not relevant to most of our audience. Consider revising your question so that it appeals to a broader audience. As it stands, the question is unlikely to help other users (regarding typo questions, see this meta question for background)." – Max Vernon, RLF, RolandoMySQLDBA, ypercubeᵀᴹ
If this question can be reworded to fit the rules in the help center, please edit the question.

  • We can't answer this question. You could have 35GB of a .sql file that is a bunch of inserts of a tinyint into tables and columns with extremely long names. Impossible for us to guess how big the eventual data will be based on the textual size of the insert statements... – Aaron Bertrand Jan 9 '15 at 18:13

Database size in InnoDB tablespace totally depends on the data. It can be larger than the SQL dump or smaller.

On one hand InnoDB has some overhead that tends to make the tablespace larger.

On other hand some fields values in the SQL dump use more space than in the tablespace. For example, integer value 1234567890123 uses 13 bytes as a string, but just 4 bytes and a value of INT type.

Not the answer you're looking for? Browse other questions tagged or ask your own question.