Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 24
Default Deleting Rows in Large Table

I'm working with a large data set in Excel, over 38,000 rows. I'm trying to
combine two such sets, then do some pivots, but because the combined table is
too large, I need to eliminate some unecessary data.

My approach so far has been to pull in the first set, then run through each
row to find the rows I can eliminate, then delete each one. In this case,
I'm trying to delete any row with "2007" as the year. Everything seems to be
working, but once the code finds the 2007 rows, it's taking a very long time
to run through the data. I've already turned off screen refresh, and set
calculation mode to manual, but it's still taking a very long time.

When I run though the code step by step, I don't detect any pauses or
problems deleting the rows. It seems to run thorugh process very quickly.

Is there any reason why this should take a long time? Is there a better
approach for doing this?

Thanks,
Todd

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,986
Default Deleting Rows in Large Table

You might get better results if you post the code you are currently using to
do the deletions. Otherwise, there is nothing to compare to for determining
if there is a better way.

"T. Jenkins" wrote:

I'm working with a large data set in Excel, over 38,000 rows. I'm trying to
combine two such sets, then do some pivots, but because the combined table is
too large, I need to eliminate some unecessary data.

My approach so far has been to pull in the first set, then run through each
row to find the rows I can eliminate, then delete each one. In this case,
I'm trying to delete any row with "2007" as the year. Everything seems to be
working, but once the code finds the 2007 rows, it's taking a very long time
to run through the data. I've already turned off screen refresh, and set
calculation mode to manual, but it's still taking a very long time.

When I run though the code step by step, I don't detect any pauses or
problems deleting the rows. It seems to run thorugh process very quickly.

Is there any reason why this should take a long time? Is there a better
approach for doing this?

Thanks,
Todd

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 24
Default Deleting Rows in Large Table

I may have come up with a solution. I was originally cycling through every
rough, checking for the cell entry, and deleting if it matched my criteria.
I'm now trying to use Autofilter to just select those rows that match my
criteria.

If this doesn't work, I'll reply with a copy of the code.

Thanks,
Todd


"JLGWhiz" wrote:

You might get better results if you post the code you are currently using to
do the deletions. Otherwise, there is nothing to compare to for determining
if there is a better way.

"T. Jenkins" wrote:

I'm working with a large data set in Excel, over 38,000 rows. I'm trying to
combine two such sets, then do some pivots, but because the combined table is
too large, I need to eliminate some unecessary data.

My approach so far has been to pull in the first set, then run through each
row to find the rows I can eliminate, then delete each one. In this case,
I'm trying to delete any row with "2007" as the year. Everything seems to be
working, but once the code finds the 2007 rows, it's taking a very long time
to run through the data. I've already turned off screen refresh, and set
calculation mode to manual, but it's still taking a very long time.

When I run though the code step by step, I don't detect any pauses or
problems deleting the rows. It seems to run thorugh process very quickly.

Is there any reason why this should take a long time? Is there a better
approach for doing this?

Thanks,
Todd

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 141
Default Deleting Rows in Large Table

On Apr 5, 9:08*am, T. Jenkins
wrote:
I may have come up with a solution. *I was originally cycling through every
rough, checking for the cell entry, and deleting if it matched my criteria.. *
I'm now trying to use Autofilter to just select those rows that match my
criteria.

If this doesn't work, I'll reply with a copy of the code.

Thanks,
Todd



"JLGWhiz" wrote:
You might get better results if you post the code you are currently using to
do the deletions. *Otherwise, there is nothing to compare to for determining
if there is a better way.


"T. Jenkins" wrote:


I'm working with a large data set in Excel, over 38,000 rows. *I'm trying to
combine two such sets, then do some pivots, but because the combined table is
too large, I need to eliminate some unecessary data.


My approach so far has been to pull in the first set, then run through each
row to find the rows I can eliminate, then delete each one. *In this case,
I'm trying to delete any row with "2007" as the year. *Everything seems to be
working, but once the code finds the 2007 rows, it's taking a very long time
to run through the data. *I've already turned off screen refresh, and set
calculation mode to manual, but it's still taking a very long time. *


When I run though the code step by step, I don't detect any pauses or
problems deleting the rows. *It seems to run thorugh process very quickly.


Is there any reason why this should take a long time? *Is there a better
approach for doing this?


Thanks,
Todd- Hide quoted text -


- Show quoted text -


Hi Todd,

You'd probably want to use AdvancedFilter rather than AutoFilter.

Cheers,
Ivan.
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
respostX2 - deleting blank rows after macro-generated pivot table klysell Excel Programming 0 February 11th 08 04:51 PM
respostX2 - deleting blank rows after macro-generated pivot table klysell Excel Programming 0 February 11th 08 04:50 PM
deleting rows in large database (+20k rows) mwam423 Excel Programming 4 August 9th 07 01:06 AM
Excel 2007 - Deleting Rows from a Table with AutoFilter TomC[_2_] Excel Programming 1 March 9th 07 10:10 PM
Pivot Table - Deleting data rows while maintaining them in the tot Robert Hamilton Excel Worksheet Functions 0 June 7th 06 07:39 PM


All times are GMT +1. The time now is 01:44 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"