If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > Performance difference between drop tbs vs drop table

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 10-23-08, 15:21
Cougar8000 Cougar8000 is offline
Registered User
 
Join Date: Nov 2005
Location: IL
Posts: 554
Question Performance difference between drop tbs vs drop table

I have done an unthinkable and read the manual on tablespaces. And I have stumbled on something that I can not find an explanation for and hope that you guys can help me out here. here is what I found.

This topic can be found in: Administration Guide: Planning

If you need to drop and redefine a particular table often, you may want to define the table in its own table space, because it is more efficient to drop a DMS table space than it is to drop a table.

Question is:"Why is it faster to drop a table space with the table in it, then simply drop redefine a particular table?"

I know it got to be very simple, but I am drawing a blank on it.

Thank you in advance.
__________________
--
IBM Certified DBA on DB2 for Linux, UNIX, and Windows

DB2 v9.1.0.2 os 5.3.0.0
Reply With Quote
  #2 (permalink)  
Old 10-23-08, 16:00
madhu_kaza madhu_kaza is offline
Registered User
 
Join Date: Apr 2008
Posts: 39
When we drop a table space, it will also drop all the tables as long as it does not have other related objects in other tablespaces(like data in one table space and indexes in another table spaces).

When we drop a table space, DB2 does not log all of the row and page deletions as it does for a drop table operation. Hence dropping a table space is much efficient than dropping a table.

Hope this helps.

Thanks,
Madhavi.
Reply With Quote
  #3 (permalink)  
Old 10-23-08, 16:38
Cougar8000 Cougar8000 is offline
Registered User
 
Join Date: Nov 2005
Location: IL
Posts: 554
right, that I am aware of. I was just wondering if I was missing some other point.

Thank you.
__________________
--
IBM Certified DBA on DB2 for Linux, UNIX, and Windows

DB2 v9.1.0.2 os 5.3.0.0
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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