January 18, 2008 at 4:39 am
Hi,
this is more a learning question than anything else. I have a process in which i am thinking of pinning a small lookup table to memory using the DBCC PINTABLE, the table space details can be viewed below.
Table Name/Record Count/Reserved/Data/Index Size/Unused
TBL_00000_SITE_MAPPING10 40 KB8 KB32 KB0 KB
My question is when the dbcc command pins the table to memory, does it only pin the 8KB of data or does it also pin the 32K of index?
Thanks
January 18, 2008 at 5:39 pm
Drop all indexes on this table.
SQL Server uses indexes to find the page with requested data.
You whole table fits in one page. Any index on this table is just a waste of space.
_____________
Code for TallyGenerator
January 18, 2008 at 7:44 pm
Also, not sure why you'd bother pinning it... it will certainly fit in cache.
--Jeff Moden
Change is inevitable... Change for the better is not.
January 19, 2008 at 9:21 am
Almost certainly this will be left in memory if it's queried with any frequency, no need to pin it.
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply