Specialized Administration > Tailoring Business Objects > Type and Attribute Management > Type and Attribute Management Command-Line Tools > Adding Columns to Types > AddColumns Report and Addressing Warnings
  
AddColumns Report and Addressing Warnings
Running the AddColumns tool with the -r parameter returns a report of the all column information for the specified type. The report compares the database, the local attribute column schema file (AddColumnsSchema.xml), introspection files, and class files for the specified type and reports on the following:
Column counts for each column data type:
The total column count for the data type.
The reserved column count for the data type (the number of columns reserved for attributes provided out-of-the-box by PTC).
The unallocated column count for the data type (the number of columns not yet in use).
Column order.
String data type column size.
The total column count in use for the type. This includes both the local attribute columns listed in the report, and all other columns on the type.
The number of columns that can still be added for the type, based on column data type, before the maximum allowed column count is reached.
If there is a mismatch in any of this information between the database, local attribute column schema file, introspection files, and class files, and the wt.properties file (for String column sizes, only), the report warns of the inconsistent information, and details the information found in each source.
The following is an example of the report for a type when all information is consistent:
Total String column count = 20
Reserved String column count = 0
Unallocated String column count = 11

Total Long column count = 21
Reserved Long column count = 0
Unallocated Long column count = 19

Total Double column count = 20
Reserved Double column count = 0
Unallocated Double column count = 20

Total Boolean column count = 20
Reserved Boolean column count = 0
Unallocated Boolean column count = 20

Total Timestamp column count = 20
Reserved Timestamp column count = 0
Unallocated Timestamp column count = 20

Total ObjectReference column count = 3
Reserved ObjectReference column count = 0
Unallocated ObjectReference column count = 3

Total VersionReference column count = 3
Reserved VersionReference column count = 0
Unallocated VersionReference column count = 2

Total InlineBLOB column count = 20
Reserved InlineBLOB column count = 0
Unallocated InlineBLOB column count = 20

All Column Counts Match.

Column Order Matches.

String column size: 500 Bytes (Database)
String column size: 500 Characters (AddColumnsSchema.xml)
String column size: 500 Characters (wt.properties)
String column size: 500 Characters (Introspection)
String column size: 500 Characters (Class)

This type has a total of 159 database columns.
You may continue to add an additional 96 columns of String, Long, Double, Boolean
or an additional 48 columns of InlineBLOB
or an additional 30 columns of ObjectReference, VersionReference
before the maximum allowed database columns is reached.
The following is an example of the portion of the report when the total column counts for a data type are inconsistent:
Total Long column count = 20 (Database) **WARNING
Total Long column count = 20 (AddColumnsSchema.xml) **WARNING
Total Long column count = 21 (Introspection) **WARNING
Total Long column count = 21 (Class) **WARNING
Reserved Long column count = 0
Unallocated Long column count = 11
If you have run the tool with the -a parameter without then running the command with the -u parameter, the report shows that the class and introspection files have larger column counts than the database and the AddColumnsSchema.xml file.
If you want to keep those additional columns, run the AddColumns tool with the -u parameter.
If you do not want to keep those additional columns, run the AddColumns tool with the -syncFromDB parameter.
* 
Once the database has been updated, either by running the AddColumns tool in plain mode, or running the AddColumns tool with the -u parameter, the database has been permanently updated. There is no supported method for removing columns once they have been added to the database.
If the report warns of column order mismatches, run the AddColumns tool with the -syncFromDB parameter, then re-apply any changes that you were attempting to make. Column order mismatch warnings appear similar to the following:
The column at index 1 does not match:
IDA3B2TYPEINFOWTPART IDA3B2 (Database) **WARNING
VersionReference (AddColumnsSchema.xml) **WARNING
ptc_ref_2.key.id idA3B2 (Introspection) **WARNING
ptc_ref_2 idA3B2 (Class) **WARNING
If you have set the com.ptc.core.lwc.string.ColumnSizes property to a larger value for the String data type column size for a type, but have not yet run the AddColumns tool with the -stringSize parameter to add additional columns and update the existing String data type column sizes, the report includes a warning similar to the following:
String column size: 500 Bytes (Database)
String column size: 500 Characters (AddColumnsSchema.xml)
String column size: 600 Characters (wt.properties)
String column size: 500 Characters(Introspection)
String column size: 500 Characters (Class)

WARNING: The String column size does not match in all sources. Investigate the mismatch and fix as needed.
Once you run the AddColumns tool with the -stringSize parameter to add additional columns to that type and update the existing String data type column sizes for that type, the String column size counts will match.