[SOLVED] Storing a Space instead of a Null for selected fields

Author: neill.king@travelport.com (Neill)

The default behavior for Uniface is: By default, non-mandatory fields that are left blank are stored with database NULLs in columns that allow it. This can be overridden using either the $FILL_DBMS_FIELDS or a driver specific setting (in this case I am using DB2 so you could set USYS$DB2_PARAMS nulldefault = N), but these are global settings affecting everything. I want to store a space for only a couple of fields in one table which can also have nulls, as an exception to the general storage of the nulls, so need some way of doing that for these fields only. We are looking at the possibility of using Triggers in DB2 to handle this, but would prefer a method we could implement in Uniface itself.  Anyone out there have any suggestions? Many Thanks  


  1. Treat such cases by changing the trigger encryption / decryption of the fields in the model can be an option.

    Author: rcmazzei (rcmazzei@outlook.com)
  2. Of course! So long since I've used Encrypt/Decrypt I'd forgotten all about it. Thanks - that looks like it could be the simple solution I've been after. Laugh

    Author: Neill (neill.king@travelport.com)