After you have expanded your system, analyzed tables for map usage, and moved tables to other AMPs as needed, analyze whether space limits and skew settings need adjustment. Use the AdjustSpace procedure to adjust the permanent space quota and perm skew limit for one or more databases. This procedure adjusts the perm space quota to be as close as possible to current perm use while leaving extra buffer space for future additions to the database. The following example adjusts space settings for all the databases in the system with the default buffer percentage:
CALL TDMaps.AdjustSpace(NULL, NULL, NULL, OutInfo);
This example sets the extra buffer space for the FINANCE database to 5%:
CALL TDMaps.AdjustSpace('FINANCE', 5, NULL, OutInfo);
TDMaps.SpaceSettingsTbl contains the default values for the AdjustSpace procedure, which a DBA can change as needed. The default buffer space is 10% and the rounding multiple for skew is 5%.
DBAs can use the AddDBInExcludeList macro to exclude databases that do not need space readjustments from the AdjustSpace procedure. The following example adds database SALES_DB to an exclusion list so that SALES_DB is skipped when AdjustSpace is running on all databases.
EXEC TDMaps.AddDBInExcludeList('SALES_DB');
DBAs can also use the DelDBInExcludeList macro to include a database previously excluded from the AdjustSpace procedure. The following example removes SALES_DB from an exclusion list so that SALES_DB is not skipped when AdjustSpace is running on all databases:
EXEC TDMaps.DelDBInExcludeList('SALES_DB');