Data Dictionary size and database space actually saved

johndanter

Legendary Poster
Hi guys,

I am not sure if this should go in the CNC part or here.

We are currently undertaking in a Database limiting exercise and looking at some of our big space sucking tables. Some are custom

If I declare a DD item as a 10 long string (2 in Data Type - Class blank) and use this in a custom table and there is nothing entered by the user for this particular DD item, I see the database has actually allocated 10 bytes worth of spaces.

So am I right in thinking if I want the database to save ZERO bytes for this blank string field then I should create the DD item with using 20 in the data type and class = VARLEN

This way it will save zero bytes for this column and save space

Is that correct?

Why is there a difference anyway? surely VARLEN is what you want for optimisation of space for all string fields?

Also if I now change these DD items (we have 25 taking up loads of space) what would I need to do to ensure the E1 system still works correctly and all is ok?
I know it's bad to change DD items, so want advise on the 2 subjects above

Thanks

John

PS: as an aside, these records are actually populated externally via excel, so this could explain the spaces but even the DB shows NCHAR 10 for these 2 String 10 fields
 
Last edited:
Top