Case-Sensitivity in Archibus

Archibus controls the case of strings entered into forms based on the “String Format” setting of the strings as defined in the Archibus Fields table. For instance, Account Code (ac.ac_id) has a String Format of UPPER, so Archibus forms force all values to uppercase. If you want to change this behavior on a field, you change that fields String Format setting.

This same String Format property controls the case behavior of the User Name and Password fields of the Archibus Users table. If you want to change the default behavior (which is to use uppercase for User Name), then change the String Format property of these fields in the Archibus Fields table.

If you are using SSO or LDAP configurations, see LDAP Configuration and SSO Configuration.

Technical Details

In the Archibus schema, you can specify

afm_flds.string_format = Upper, UpperAlpha, UpperAlphaNum

values (among others). Those values mean that:

1. The corresponding value should be converted to uppercase when crossing the boundary of Archibus products:

2. As a consequence, the corresponding variable will have uppercase value in memory (JS, C#, Java, etc. memory).

3. As a consequence, the corresponding field will have an uppercase value in the database.

Rule to Remember

By applying the case-sensitivity setting at the border, the system guarantees that all values will have the correct values in memory (JS, C#, Java, etc. memory) and in the database.

Values, generated in memory:

The developer must apply the case-sensitivity setting to the values of the fields generated in memory (hardcoded, concatenated, etc.that is, values not coming from the user interface, memory, or database) .

This means that when you are generating programmatically values for any string-type based fields (e.g. any non-numeric, non-date/time type), your code must check the value of its Upper property of the FieldDef.Formatting, and if it is true, convert the value to uppercase.

Case and String Format Fields

Case-Sensitivity and File Names

Note: The system uses uppercase the drawing file names when it enters the names in the user interface. The system uses lowercase the files when it publishes enterprise graphics. But the original DWG file name on disk can be mixed case. This means that after the system stores the names of files in the database, the names don’t match the names on the disk anymore (unless the OS is case-insensitive).

The same thing occurs with enterprise graphics files. However, the system can use the enterprise graphics because it consistently uses lowercase for them. For CAD files, this situation works since the CAD editing tools are available only on Windows and Windows is case-insensitive

Password

Password is a special case. If you specify:

afm_flds.string_format = Upper, UpperAlpha, UpperAlphaNum

for a password field (afm_users.user_pwd, afm_users.sql_pwd , afm_roles.sql_pwd):

  1. The password value will be converted to uppercase on the SignIn form (unless security configuration is LDAP), and on the edit form (e.g. password change form).
  2. As a consequence, the corresponding variable will have an uppercase value in memory (JS, C#, Java, etc. memory).
  3. The password value will be encoded (for afm_users.user_pwd if useEncoding=true in passwordManager.xml; for afm_users.sql_pwd, afm_roles.sql_pwd if SQL password decoder bean is specified in WEB-INF/config/context/security/afm_users/sql-security/password-encoder.xml).
  4. The encoded value will be converted to uppercase.
  5. As a consequence, the corresponding variable will have an uppercase value in memory (JS, C#, Java, etc. memory);
  6. As a consequence, the corresponding field will have an uppercase value in the database.