# Table size

**URL:** <https://forum.kx.com/t/table-size/11457>\
**Category:** Community Support\
**Tags:** kdb-and-q\
**Created:** [January 19, 2017, 3:42am UTC](https://forum.kx.com/t/table-size/11457 "2017-01-19T03:42:00Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![vortexsbkny](https://avatars.discourse-cdn.com/v4/letter/v/45deac/32.png) [@vortexsbkny](https://forum.kx.com/u/vortexsbkny)\
**Post date:** [January 19, 2017, 3:42am UTC](https://forum.kx.com/t/table-size/11457/1 "2017-01-19T03:42:00Z")

</div>

Hi,

I am having trouble retrieving size of a splayed, partitioned table. _-22!_ reports a tiny number, few hundred bytes. I assume it does so because  
entire table is not memory. Related question. If I were to execute _count very\_large\_table_, does KDB have to fit whole table  
into memory or does it scan one partition after another?

Thanks

---

<div class="post-metadata">

**Author:** ![fealyjason](https://avatars.discourse-cdn.com/v4/letter/f/51bf81/32.png) [@fealyjason](https://forum.kx.com/u/fealyjason)\
**Post date:** [January 19, 2017, 5:17pm UTC](https://forum.kx.com/t/table-size/11457/2 "2017-01-19T17:17:00Z")

</div>

Hi,

See the below link for a useful utility, which you can use to create a dictionary mapping each partition name to its row count.

http://code.kx.com/wiki/DotQ/DotQDotpn

Jason

---

<div class="post-metadata">

**Author:** ![vortexsbkny](https://avatars.discourse-cdn.com/v4/letter/v/45deac/32.png) [@vortexsbkny](https://forum.kx.com/u/vortexsbkny)\
**Post date:** [January 20, 2017, 3:12am UTC](https://forum.kx.com/t/table-size/11457/3 "2017-01-20T03:12:00Z")

</div>

Thank you, for others readers&nbsp;.Q.pv!flip .Q.pn

---

<div class="post-metadata">

**Author:** ![vortexsbkny](https://avatars.discourse-cdn.com/v4/letter/v/45deac/32.png) [@vortexsbkny](https://forum.kx.com/u/vortexsbkny)\
**Post date:** [January 20, 2017, 3:12am UTC](https://forum.kx.com/t/table-size/11457/4 "2017-01-20T03:12:00Z")

</div>

On Thursday, January 19, 2017 at 4:56:44 AM UTC-5, gekaprog wrote:

> Hi,
> 
> I am having trouble retrieving size of a splayed, partitioned table. _-22!_ reports a tiny number, few hundred bytes. I assume it does so because  
> entire table is not memory. Related question. If I were to execute _count very\_large\_table_, does KDB have to fit whole table  
> into memory or does it scan one partition after another?
> 
> Thanks
