I have an excel file close to 300MB. There are a few tabs and are all text based.
All fonts are the same. Some are characters and some are date formats. one tab is close to 1M row now. But the number of columns in all tabs are only less than 30. No macros included or links to other files.
I read that Excel limit is ~1M rows X 2000 columns. Does that mean as long as my columns are less than 30, then this file can still potentially grow? Or would it just stop running once it reaches 1M?
thanks in advance.
Once you have 2^20 (1048576) rows you will not be able to add a new row. In order to understand this, select range A1 and keep pressing Ctrl+Down arrow until you see the last row. Once you reach it, you cannot go further.
Concerning the 1.000.000+ entries and the need for more rows - it seems that you are using Excel as a database, and it is really not a good idea to use it as one. If you need so many entries, you probably need a nice database, which would be fast and easy. MS Access (as far as you are using Excel, this is the db with most similar interface) can solve your solution easily. Or MS SQL Server.
Related
I have used Excel for quite some time now but only using traditional formulas. Now I am trying to create a more elaborated document for my business using VBA coding to expand my possibilities.
I have done some research and started practicing but found something that I can’t understand how to do yet.
I have a worksheet with a table on it. Since this is a fresh document it has nothing but the header and a blank row below it. What I always did when writing the information was type text in any of the columns that belong to the row immediately below the table (without actually inserting a new row myself). This creates a new row for the table where most of its format is kept, such as text size and formulas. However, I noticed that the row height doesn’t automatically change to that of the previous rows of the table, and changing it manually for each new row is very time consuming.
I would really appreciate it if anyone could share me the necessary Excel VBA code to fix this issue. I have thought of two possible approaches. The first one is a code that automatically sets all the rows of the table to a height of 20 (I want all rows to be the same size so no problem with that), supposing this would also affect new rows as I add them the way I mentioned. The second one would be a code that automatically sets every new row of the table to a size of 20. It doesn’t matter which one you choose, the easiest will be just fine. Thanks in advance.
I want to create a pretty big table in excel.
I have 4000 rows and 70 columns, I have images that are locked into cells as well.
Do I have a chance this table creation process will work, or will excel be stuck?
Is there a workaround maybe?
any help will be much appreciated.
Excel doesn't have a hard cap on it's rows / column count (well it does but it's astronomical), although once reaching certain thresholds, it might be preferable to move towards a database solution. Have you considered creating a small MySql server instead of using excel files?
For excel limitations see : https://support.office.com/en-us/article/data-model-specification-and-limits-19aa79f8-e6e8-45a8-9be2-b58778fd68ef
I have an empty excel file, which is 5.5mb large.
If I open it - the process is very laggy, even on fast PC (intel i7 processor).
It opens ~30 sec.
When it opens, it shows that the document has 1048576 rows.
I tried to delete them - but unsuccessfully.
If I remove the G column, the file size gets decreased by half (2.5mb).
If I remove the Entire Sheet, adding new empty one, the file size gets 8kb.
The question is not about how to solve the problem, but what does cause the problem, why this is happening and how do I remove unused rows? I tried to delete them in different ways. saved the document-reopened - no success.
Here is the document, if you need: https://files.fm/u/erfr4weq
Save the excel file with the open xml format, unrar and open it with the editor to see what is going on in it.
Please note that this approach is only valid for xlsx files (office 2007 and onwards)
It's most likely not actually empty, there will be some hidden data somewhere. Try the clear function on excel instead of just the delete button.
I had the same thing happen.
I had 1200 data records that took up 5MB, which is odd.
I looked at the right scroll bar and saw that it was small. Excel had added 10,000 more rows, which I found out.
I got rid of the extra rows, so it is now 152kb.
Check to see if the number of rows on your scroll bar matches the number of rows you're using.
Then get rid of them.
Even though it looks like you're not deleting anything, you are.
So something happened twice that has caused me hours of retroactive work. Extremely, extremely annoying, and the bain of my existence.
I have an .xls file with about 171K rows. I saved it with filters on, reducing the number of shown rows to about 13K. When I reopened the file the next day the filters were not showing, but rows were 'hidden', because in order to show all the rows I had to 'unhide'. The problem is that when I unhide, the total rows is ~65K aka the last numbered row that was showing when I had filters on.
Has this happened to anyone before or know how to recover the full 171K rows? I know for a fact I didn't 'clear' or 'delete' anything before or after saving.
One piece of advise I have is for you to start reading screen prompts. When saving a large file with over 65536 rows this kind of warning is displayed. Only you can prevent your own errors.
You can avoid this by making a copy of the original and filtering on that, then you always have the source if you make an error.
I have a large Excel file consisting of multiple data sheets with plain data and a couple of dashboard sheets with various graphs and kpi's based on these data.
I am looking to make the file smaller and faster to work with. Should I convert the unformatted data to tables or not. I can't really find anything to support this.
Anyone got any ideas?
Tables have a lot of benefits but they are generally slower than plain data, (although the latest version of Excel 2016 has significant Table speed improvements).
You're actually asking the wrong question. The questions you should be asking is "Why is Excel taking so long to recalculate, why is my filesize so large, and what can I do about it?"
And you don't give us much info about your symptoms. How large is your file in MB? How many rows of data in it? Lots of lookups on big ranges? Lots of volatile functions like OFFSET, INDIRECT at the head of long dependency chains? How slow is it? What version/SKU of Excel do you have?
If Excel runs slowly, it's generally because people have inadvertently programmed it to run slowly, due to poor formula choice and suboptimal layout. Converting to Tables or not isn't going to make a hell of a lot of difference, by the sound of things.
Common culprits that result in slow files include the following (note the last one re Tables) :
Volatile Functions with long calculation chains running off them. See
my post at
https://chandoo.org/wp/2014/03/03/handle-volatile-functions-like-they-are-dynamite/
for more on this
Inefficient lookups on multiple columns (such as using multiple
VLOOKUPS to bring through data for the same record rather than using
one MATCH and multiple INDEX functions)
Lookups on very, very long arrays. See my post at
http://dailydoseofexcel.com/archives/2015/04/23/how-much-faster-is-the-double-vlookup-trick/
to learn how sorting your lookup tables and using the binary match
parameter can speed up lookups thousands fold.
Overuse of resource-intensive formulas such as SUMPRODUCT, when
simpler alternatives exist (including SUMIF and it's variants, or even better, PivotTables)
Using IF and other functions to change the formatting of thousands of cells, instead of using custom number formatting
Using Data Tables. (These can really hog resources, and sometimes
better alternatives exist)
Using many thousands of extra formulas to reference data input cells
that might not be used, rather than using Excel Tables (aka
ListObjects) that expand dynamically, automatically. I always use Tables to host my data and settings. They radically simplify referencing (including from VBA) and file maintainability.
You need to address the root cause, not the symptoms. A good place to start is this article by recalculation guru Charles Williams (who I see has dropped by):
https://msdn.microsoft.com/en-us/vba/excel-vba/articles/excel-tips-for-optimizing-performance-obstructions
In terms of file size, as Charles Williams puts it: To save memory and reduce file size, Excel tries to store information about the area only on a worksheet that was used. This is called the used range. Sometimes various editing and formatting operations extend the used range significantly beyond the range that you would currently consider used. This can cause performance obstructions and file-size obstructions.
You can check what Excel thinks is the used range by pushing Ctrl + End. If you find yourself miles below or to the right of where your data ends, then delete all the rows/columns between that point and the edge of your data:
To quickly do the rows, select the entire row that lies beneath the
bottom of your data, then push Ctrl + Shift + Down Arrow (which
selects all the rows right to the bottom of the spreadsheet) and then
using the Right-Click DELETE option.
For columns, you would select the entire column to the immediate
right of your data, and use the using Ctrl + Shift + Right Arrow to
select the unused bits, and then use the Right-Click DELETE option.
(Note that you’ve got to use the Right-Click DELETE option, and not just push the Delete key on the keyboard.)
When you’ve done this, then push Ctrl + End again and see where you end up – hopefully close to the bottom right corner of your data. Sometimes it doesn’t work, in which case you need to push Alt + F11 (which opens the VBA editor) and type Application.ActiveSheet.UsedRange in the Immediate Window and then pushing ENTER (and if you can’t see a window with the caption “Immediate” then push Ctrl G).
Lastly, depending on what version and SKU of Excel you have, you may be able to use PowerPivot and PowerQuery to radically simplify things and drastically cut down on the amount of formulas in your workbook.