What is Size Category?

In this article, you will find answers to the most asked questions from newbies about Size Category that we are getting in ABAP Academy.

Notice: We will use the abbreviation SC for Size Category in this article.

Q: What is Size Category?

The SC is basically our “estimation” of how many records the database table we are creating is going to contain.

Of course, nobody knows the exact number. That’s why we want to shoot our best ;).

Q: Why estimate Size Category?

When creating a database table, we need to let SAP know how much space needs to be allocated physically to database storage. By providing SC we help the database to allocate enough space.

Q: What happens if the database table exceeds the number of records?

It’s not a problem. The database will just create another tablespace with the same SC.

Q: Isn’t it then the best thing to do to use Size Category “0” everywhere?

No! What would happen then is that each and every time database records exceed the SC number, it creates another tablespace in the very next empty space in the database. And this results into having lots of fragments, which means that processing the data in the database is much slower.

Q: Then we should rather use as high Size Category as possible everywhere, right?

No! Then we just waste the resources when creating big tablespace where nothing will be stored.

Q: Where to find this setting?

We set up the SC while creating Database Table within Technical Settings (click here to read more).

Screenshot of Size Category setting in SAP system

Summary

That’s why we use the word “estimate”, where we give our best “guess” to the database to optimize the tablespace allocation because only we as technical people know how many records we can approximately expect.

Theory about Size Category

.. and if you want to know more, here is something about the theory.

SAP defines it as the expected space required for the table in the database initially and if the initial space is not enough, the same amount of space is reallocated when required. Each category has assigned a certain fixed memory size in the database, which depends on the database system used.

There are 9 Size Categories, from 0-9. The higher the number, the bigger the allocation space. The image above shows estimation records for each SC.

For more information about this topic, you can find it in the official SAP documentation.

Comments

Add a comment

Your email address will not be published. Required fields are marked *

 

Your personal information will be exclusively used for processing current comment only. Personal data protection policy